/**
 * Стили для модального окна проектов
 * Полноэкранное модальное окно с детальной информацией
 */

/* ===== МОДАЛЬНОЕ ОКНО ===== */
.project-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-modal.active {
  display: flex;
  opacity: 1;
}

/* ===== ОВЕРЛЕЙ ===== */
.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
}

/* ===== КОНТЕЙНЕР МОДАЛЬНОГО ОКНА ===== */
.modal-container {
  position: relative;
  width: 90%;
  max-width: 1200px;
  height: 90%;
  max-height: 800px;
  margin: auto;
  background: rgba(16, 41, 48, 0.95);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.project-modal.active .modal-container {
  transform: scale(1);
}

/* ===== ЗАГОЛОВОК МОДАЛЬНОГО ОКНА ===== */
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 30px;
  background: rgba(208, 200, 150, 0.1);
  border-bottom: 2px solid rgba(208, 200, 150, 0.3);
}

.modal-title {
  font-size: 2rem;
  color: #d0c896;
  margin: 0;
  font-family: 'Besom-2';
}

.modal-close-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #d0c896;
  border: none;
  color: #0e1b21;
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  background: #b8a882;
  transform: scale(1.1);
}

/* ===== ТЕЛО МОДАЛЬНОГО ОКНА ===== */
.modal-body {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  padding: 30px;
  overflow-y: auto;
}

/* ===== СЛАЙДЕР ИЗОБРАЖЕНИЙ ===== */
.modal-image-slider {
  position: relative;
}

.modal-slider-container {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-slider-track {
  display: flex;
  transition: transform 0.5s ease;
}

.modal-slider-slide {
  min-width: 100%;
  height: 400px;
  position: relative;
}

.modal-slider-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(208, 200, 150, 0.9);
  border: none;
  color: #0e1b21;
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.modal-slider-btn:hover {
  background: #d0c896;
  transform: translateY(-50%) scale(1.1);
}

.modal-slider-prev {
  left: 15px;
}

.modal-slider-next {
  right: 15px;
}

.modal-slider-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 10px;
}

.modal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(208, 200, 150, 0.3);
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-dot.active {
  background: #d0c896;
  transform: scale(1.2);
}

/* ===== КОНТЕНТ МОДАЛЬНОГО ОКНА ===== */
.modal-content {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.modal-description,
.modal-features,
.modal-technologies {

  background: rgba(0, 0, 0, 0.2);
  padding: 20px;
  border-radius: 10px;
  border-left: 4px solid #d0c896;
  font-family: 'BellotaText';
}

.modal-description h3,
.modal-features h3,
.modal-technologies h3 {
  color: #d0c896;
  margin: 0 0 15px 0;
  font-size: 1.2rem;
  font-family: 'Besom-2';
}

.modal-description p {
  color: #ffffff;
  line-height: 1.6;
  margin: 0;
}

.modal-features ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.modal-features li {
  color: #ffffff;
  padding: 8px 0;
  position: relative;
  padding-left: 20px;
}

.modal-features li::before {
  content: '▶';
  color: #d0c896;
  position: absolute;
  left: 0;
}

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

.modal-tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 15px;
  background: rgba(208, 200, 150, 0.1);
  border-radius: 10px;
  transition: all 0.3s ease;
}

.modal-tech-item:hover {
  background: rgba(208, 200, 150, 0.2);
  transform: translateY(-2px);
}

.modal-tech-item .tech-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.modal-tech-item span {
  color: #d0c896;
  font-size: 0.9rem;
  font-weight: 500;
}

/* ===== АДАПТИВНОСТЬ ===== */
@media (max-width: 1024px) {
  .modal-container {
    width: 95%;
    height: 95%;
  }

  .modal-body {
    gap: 25px;
  }

  .modal-slider-slide {
    height: 300px;
  }
}

@media (max-width: 768px) {
  .modal-container {
    width: 100%;
    height: 100%;
    border-radius: 0;
    max-height: none;
  }

  .modal-body {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 20px;
  }

  .modal-header {
    padding: 15px 20px;
  }

  .modal-title {
    font-size: 1.5rem;
  }

  .modal-close-btn {
    width: 35px;
    height: 35px;
    font-size: 1.2rem;
  }

  .modal-slider-slide {
    height: 250px;
  }

  .modal-slider-btn {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }

  .modal-slider-prev {
    left: 10px;
  }

  .modal-slider-next {
    right: 10px;
  }

  .modal-tech-grid {
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .modal-header {
    padding: 12px 15px;
  }

  .modal-title {
    font-size: 1.2rem;
  }

  .modal-body {
    padding: 15px;
    gap: 15px;
  }

  .modal-description,
  .modal-features,
  .modal-technologies {
    padding: 15px;
    h3{
      display: none;
    }
  }

  .modal-slider-slide {
    height: 200px;
  }

  .modal-slider-btn {
    width: 35px;
    height: 35px;
    font-size: 1rem;
  }

  .modal-tech-grid {
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 8px;
  }

  .modal-tech-item {
    padding: 10px;
  }

  .modal-tech-item .tech-logo {
    width: 30px;
    height: 30px;
  }
}
