/* ========== СТИЛИ ДЛЯ ГЛАВНОЙ СТРАНИЦЫ ========== */

/* Основной контейнер с отступами и gap между секциями */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 60px;
  margin: 50px 350px 100px;
}

/* 3D ссылка на версию (только для главной страницы) */
.hero-version-link {
  color: #ffd60a;
  text-decoration: none;
  font-size: 1.5rem;
  font-weight: 700;
  display: inline-block;
  width: 100%;
  padding: 12px 30px 12px 50px;
  background: linear-gradient(145deg, rgba(255, 214, 10, 0.1), rgba(255, 214, 10, 0.05));
  border: 2px solid rgba(255, 214, 10, 0.3);
  letter-spacing: 1px;
  margin-top: 10px;
  position: relative;
  transform-style: preserve-3d;
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
}

.hero-version-link::before {
  content: '◈';
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  color: #ffd60a;
  text-shadow: 0 0 10px #ffd60a;
  animation: rotate3d 3s infinite linear;
}

@keyframes rotate3d {
  0% { transform: translateY(-50%) rotateY(0deg); }
  100% { transform: translateY(-50%) rotateY(360deg); }
}

.hero-version-link:hover {
  transform: perspective(500px) rotateX(5deg) rotateY(5deg);
  box-shadow: 0 10px 30px rgba(255, 214, 10, 0.3);
  border-color: #ffd60a;
  color: #ffffff;
}

.hero-version-link:hover::before {
  color: #ffffff;
  text-shadow: 0 0 20px #ffffff;
}

/* Секция "О себе" */
.intro {
  font-size: 0.9rem;
  color: #ffd60a;
  max-width: 600px;
  font-weight: 700;
  user-select: none;
}

.intro p {
  font-size: 1.2rem;
  margin-top: 30px;
  line-height: 1.6;
  color: #ffffff;
  font-weight: 500;
  user-select: text;
  text-align: left;
}

/* ========== ПРОЕКТЫ ========== */
.content {
  display: flex;
  flex-direction: column;
  gap: 30px;
  margin-bottom: 80px;
}

.project-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  cursor: pointer;
  user-select: none;
  margin-bottom: 20px;
  width: 100%;
}

.project-header h2 {
  font-size: 3rem;
  color: #ffd60a;
  transition: color 0.3s ease;
  line-height: 1;
}

.project-header:hover h2 {
  color: #ffffff;
}

.project.active .project-header h2 {
  color: #ffffff;
}

/* Панель описания */
.project .description {
  overflow: hidden;
  height: 0;
  background: #ffffff;
  color: #444444;
  font-weight: 600;
  padding: 0;
  transition: height 0.25s ease;
  margin-left: -350px;
  margin-right: -350px;
}

/* Контейнер для описания с баннером слева и текстом справа */
.project .description-content {
  display: flex;
  gap: 40px;
  align-items: center;
  margin-left: 350px;
  margin-right: 350px;
  padding: 50px 0;
}

/* Баннер слева - уменьшен на 25% (было 400px, стало 300px) */
.project-banner-side {
  flex: 0 0 300px;
  overflow: hidden;
  background: #000;
  align-self: center;
  cursor: pointer;
  position: relative;
}

/* Стили для изображения и GIF */
.project-banner {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  transition: transform 0.5s ease, filter 0.5s ease;
}

/* Поддержка GIF - они будут вести себя так же */
img.project-banner[src$=".gif"] {
  image-rendering: crisp-edges;
}

/* При наведении на контейнер баннера */
.project-banner-side:hover .project-banner {
  transform: scale(1.03);
  filter: brightness(0.8);
}

/* Текстовый блок справа — содержит текст и кнопки под ним */
.project-description-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.project-description-text p {
  text-align: justify;
  line-height: 1.6;
  font-size: 1.2rem;
  color: #444444;
  font-weight: 600;
  margin-bottom: 30px;
}

/* Группа кнопок — под текстом */
.project-links {
  margin-top: 0;
  display: flex;
  gap: 60px;
}

.project-link {
  color: black;
  text-decoration: none;
  font-weight: 800;
  font-size: 1.4rem;
}

/* ========== АДАПТИВНОСТЬ ========== */
@media (max-width: 1200px) {
  .sidebar {
    margin: 40px 100px;
  }
  .project .description {
    margin-left: -100px;
    margin-right: -100px;
  }
  .project .description-content {
    margin-left: 100px;
    margin-right: 100px;
  }
  /* На планшетах тоже уменьшаем баннер */
  .project-banner-side {
    flex: 0 0 260px;
  }
}

/* Планшеты и маленькие экраны - скрываем баннер */
@media (max-width: 900px) {
  .project-banner-side {
    display: none;
  }
  
  .project .description-content {
    gap: 0;
  }
  
  .project-description-text {
    flex: 1;
  }
}

@media (max-width: 768px) {
  .sidebar {
    margin: 30px 20px;
    gap: 40px;
  }
  .project-header h2 {
    font-size: 2rem;
  }
  .project .description {
    margin-left: -20px;
    margin-right: -20px;
  }
  .project .description-content {
    margin-left: 20px;
    margin-right: 20px;
    padding: 30px 0;
    flex-direction: column;
  }
  .intro p {
    font-size: 1rem;
  }
  .hero-version-link {
    font-size: 1rem;
    padding: 10px 20px 10px 40px;
  }
  .hero-version-link::before {
    font-size: 1rem;
    left: 12px;
  }
  .project-description-text p {
    font-size: 1rem;
    margin-bottom: 20px;
  }
  .project-links {
    gap: 30px;
  }
  
  /* На мобильных баннер скрыт */
  .project-banner-side {
    display: none;
  }
}

@media (max-width: 480px) {
  .project .description-content {
    margin-left: 15px;
    margin-right: 15px;
    gap: 15px;
  }
}