/* style.css */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700;900&display=swap');
@import url(../vendor/normalize.css);
@import url(../pages/footer.css);
@import url(../pages/header.css);
@import url(../pages/hero.css);
@import url(../pages/projects.css);
@import url(../pages/resources.css);
@import url(../pages/slogan.css);

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  max-width: 100%;
  /* box-shadow: 0 0 0 1px rgba(255, 0, 0, 0.5) !important; */
}

/* Дополнительные исправления для предотвращения выезжания */
img,
svg,
iframe {
  max-width: 100%;
  height: auto;
}

/* Плавный скролл для якорей */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

.page {
  font-family: 'Roboto', sans-serif;
  background-color: #f7f9fb;
}

/* Контейнер для контента шириной 1170px и центрированием */
.container {
  width: 1170px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
}

/* Модальное окно */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  overflow: auto;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal__content {
  background-color: #fff;
  margin: 5% auto;
  padding: 30px;
  border-radius: 12px;
  width: 90%;
  max-width: 800px;
  position: relative;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal__close {
  position: absolute;
  right: 20px;
  top: 15px;
  font-size: 28px;
  font-weight: bold;
  color: #666;
  cursor: pointer;
  transition: color 0.3s ease;
}

.modal__close:hover {
  color: #de2726;
}

.modal__content h2 {
  color: #2134a0;
  margin-bottom: 15px;
  padding-right: 30px;
}

.modal__meta {
  color: #666;
  margin-bottom: 20px;
  font-size: 14px;
}

.modal__image {
  margin-bottom: 20px;
  text-align: center;
  max-height: 300px;
  overflow: hidden;
  border-radius: 8px;
}

/* .modal__image img {
  max-width: 100%;
  max-height: 300px;
  object-fit: contain;
} */

.modal__text {
  line-height: 1.6;
  font-size: 16px;
  color: #333;
  max-height: 400px;
  overflow-y: auto;
  padding: 10px 0;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.modal__image img {
  border-radius: 8px;
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}

/* Стили для большого модального окна */
.modal__content--large {
  max-width: 1200px !important;
  width: 95%;
  max-height: 80vh;
  overflow-y: auto;
}

.modal__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  padding: 20px 0;
}

.modal__card {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 1px solid #e0e0e0;
}

.modal__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  border-color: #2134a0;
}

.modal__card-title {
  font-weight: 700;
  font-size: 18px;
  color: #2134a0;
  margin-bottom: 10px;
}

.modal__card-meta {
  font-size: 12px;
  color: #949494;
  margin-bottom: 10px;
}

.modal__card-preview {
  font-size: 14px;
  color: #444;
  line-height: 1.5;
  max-height: 100px;
  overflow: hidden;
  position: relative;
}

.modal__card-preview::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 30px;
  background: linear-gradient(transparent, #f8f9fa);
  pointer-events: none;
}

/* ---------- ПЛЕЙСХОЛДЕРЫ ДЛЯ ПУСТЫХ СОСТОЯНИЙ ---------- */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 16px;
  margin: 20px 0;
  position: relative;
  overflow: hidden;
}

.empty-state::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  animation: emptyStatePulse 3s ease-in-out infinite;
}

.empty-state__icon {
  width: 120px;
  height: 120px;
  margin: 0 auto 25px;
  background: linear-gradient(135deg, #2134a0 0%, #de2726 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
  box-shadow: 0 10px 30px rgba(33, 52, 160, 0.3);
  animation: emptyStateFloat 3s ease-in-out infinite;
}

.empty-state__icon svg {
  width: 60px;
  height: 60px;
  fill: white;
}

.empty-state__title {
  font-size: 24px;
  font-weight: 700;
  color: #2134a0;
  margin-bottom: 10px;
  position: relative;
  z-index: 2;
}

.empty-state__description {
  font-size: 16px;
  color: #666;
  max-width: 400px;
  margin: 0 auto;
  line-height: 1.6;
  position: relative;
  z-index: 2;
}

.empty-state__hint {
  margin-top: 25px;
  font-size: 14px;
  color: #949494;
  position: relative;
  z-index: 2;
}

.empty-state__hint a {
  color: #de2726;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.empty-state__hint a:hover {
  color: #2134a0;
  text-decoration: underline;
}

/* Специфичные стили для анонсов */
.empty-state--announcements .empty-state__icon {
  background: linear-gradient(135deg, #2134a0 0%, #1a2a80 100%);
}

/* Специфичные стили для новостей */
.empty-state--news .empty-state__icon {
  background: linear-gradient(135deg, #de2726 0%, #b31f1f 100%);
}

/* Адаптивность */

@media (max-width: 1200px) {
  .container {
    width: 100%;
    padding-left: 20px;
    padding-right: 20px;
    box-sizing: border-box;
    overflow-x: hidden;
  }
  body {
    overflow-x: hidden;
    width: 100%;
    position: relative;
  }
}

@media (max-width: 768px) {
  .empty-state {
    padding: 40px 15px;
  }

  .empty-state__icon {
    width: 100px;
    height: 100px;
  }

  .empty-state__icon svg {
    width: 50px;
    height: 50px;
  }

  .empty-state__title {
    font-size: 20px;
  }

  .empty-state__description {
    font-size: 14px;
  }
}

/* Анимации */

@keyframes emptyStatePulse {
  0% {
    transform: scale(1);
    opacity: 0.5;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
  100% {
    transform: scale(1);
    opacity: 0.5;
  }
}

@keyframes emptyStateFloat {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}
