/* === ОБЩИЕ НАСТРОЙКИ === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Courier New', Courier, monospace;
  color: #333;
  background: #f0f0f0;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 1.5s ease;
}

body.day {
  background: linear-gradient(135deg, #e0e0e0, #c0c0c0);
  color: #222;
}

body.night {
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  color: #e0e0e0;
}

/* === ФОН ПРОФИЛЯ — как в ВК, сверху, за всем === */
.profile-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 220px;
  background: url('9pB5dKm.jpg')center/cover no-repeat;
  z-index: -1;
  opacity: 0.3;
  filter: brightness(0.7) contrast(0.8);
  border-bottom: 4px solid #555;
}

body.night .profile-bg {
  background: url('1qJ3VfO.jpg')center/cover no-repeat;
  opacity: 0.4;
  filter: brightness(0.5) contrast(1.2) grayscale(0.3);
}

/* === ПАНЕЛЬ НАВИГАЦИИ — по центру, ниже фона, острые углы === */
.nav-panel {
  display: flex;
  justify-content: center;
  background: #333;
  padding: 12px 0;
  margin-top: 220px;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-link {
  color: #ddd;
  text-decoration: none;
  padding: 8px 20px;
  margin: 0 5px;
  border-radius: 8px;
  font-weight: bold;
  transition: all 0.3s ease;
  border: 1px solid #555;
}

.nav-link:hover {
  background: #555;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.nav-link.active {
  background: #e74c3c;
  color: white;
  border-color: #c0392b;
}

/* === ОСНОВНОЙ КОНТЕНТ === */
.main-content {
  max-width: 900px;
  margin: 60px auto 40px;
  padding: 30px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 1;
}

body.night .main-content {
  background: rgba(20, 20, 30, 0.85);
  color: #e0e0e0;
  border: 1px solid #444;
}

h1 {
  font-size: 2.8rem;
  margin-bottom: 10px;
  color: #c0392b;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

h2 {
  font-size: 2rem;
  margin: 30px 0 15px;
  color: #2c3e50;
}

body.night h2 {
  color: #ecf0f1;
}

.subtitle {
  font-size: 1.2rem;
  color: #7f8c8d;
  margin-bottom: 30px;
  font-style: italic;
}

body.night .subtitle {
  color: #bdc3c7;
}

ul {
  margin: 20px 0;
  padding-left: 20px;
}

li {
  margin: 8px 0;
}

/* === СЛАЙДЕР ФОТО === */
.hero-slider {
  position: relative;
  margin: 40px 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.slider-container {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
}

.slider-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
}

.slider-img.active {
  opacity: 1;
}

.slider-dots {
  display: flex;
  justify-content: center;
  margin-top: 15px;
  gap: 8px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #aaa;
  cursor: pointer;
  transition: background 0.3s ease;
}

.dot.active {
  background: #e74c3c;
}

.dot:hover {
  background: #c0392b;
}

/* === СЕТКА ЗАПЧАСТЕЙ === */
.parts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 25px;
  margin: 40px 0;
}

.part-item {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #eee;
}

body.night .part-item {
  background: #2c3e50;
  border-color: #444;
}

.part-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.part-item h4 {
  padding: 15px;
  background: #f8f9fa;
  font-size: 1.3rem;
  color: #2c3e50;
  border-bottom: 1px solid #eee;
}

body.night .part-item h4 {
  background: #34495e;
  color: #ecf0f1;
}

.part-item p {
  padding: 15px;
  font-size: 0.95rem;
  color: #555;
  line-height: 1.7;
}

body.night .part-item p {
  color: #bdc3c7;
}

/* === ПРОБЛЕМА === */
.problem-image {
  text-align: center;
  margin: 40px 0;
}

.problem-image img {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* === ПОДПИСЬ ВНИЗУ КАЖДОЙ СТРАНИЦЫ === */
.footer-note {
  text-align: center;
  margin-top: 60px;
  font-size: 0.9rem;
  color: #888;
  font-style: italic;
  border-top: 1px dashed #ccc;
  padding-top: 20px;
}

body.night .footer-note {
  color: #7b8788;
  border-top-color: #363636;
}

/* === АДАПТИВНОСТЬ === */
@media (max-width: 768px) {
  .main-content {
    padding: 20px;
    margin: 50px 10px;
  }

  h1 {
    font-size: 2.2rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  .slider-container {
    height: 280px;
  }

  .nav-panel {
    flex-wrap: wrap;
  }

  .nav-link {
    padding: 6px 12px;
    font-size: 0.9rem;
  }
}

