/* Общие стили */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #f2f2f2;
  color: #333;
}

h1, h2 {
  color: #4B0082;
  text-align: center;
}

p {
  font-size: 1rem;
  line-height: 1.6;
}

main.content {
  max-width: 900px;
  margin: auto;
  padding: 20px;
  background: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

/* Навигация */
nav {
  background-color: #4B0082;
}

nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

nav ul li {
  margin: 0;
}

nav ul li a {
  display: block;
  padding: 15px 20px;
  color: white;
  text-decoration: none;
  transition: background-color 0.3s;
}

nav ul li a:hover {
  background-color: #6A5ACD;
}

/* Кнопки и ссылки */
.button, .link-button {
  display: inline-block;
  margin-top: 15px;
  background-color: #4B0082;
  color: white;
  padding: 10px 20px;
  text-decoration: none;
  border-radius: 8px;
  transition: background-color 0.3s ease;
}

.button:hover, .link-button:hover {
  background-color: #6A5ACD;
}

/* Галерея */
.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
}

.gallery img {
  width: 250px;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.2);
}

/* Слайдер */
.slider {
  max-width: 600px;
  margin: 20px auto;
  position: relative;
}

.slide {
  display: none;
  width: 100%;
  border-radius: 8px;
}

.slide.active {
  display: block;
}

/* Диаграммы */
.diagram {
  display: block;
  max-width: 100%;
  margin: 20px auto;
  border: 1px solid #ccc;
  border-radius: 8px;
}

/* Форма */
form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

form input, form textarea {
  padding: 10px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  width: 100%;
  box-sizing: border-box;
}

form button {
  width: fit-content;
  padding: 10px 20px;
  background-color: #4B0082;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

form button:hover {
  background-color: #6A5ACD;
}

.map-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.slider-horizontal {
  position: relative;
  overflow: hidden;
  max-width: 100%;
  margin: 20px auto;
}

.slider-track {
  display: flex;
  transition: transform 0.4s ease-in-out;
}

.slider-track img {
  min-width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
  margin: 0 auto;
}

.slide-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  color: #4B0082;
  border: none;
  font-size: 36px;
  cursor: pointer;
  z-index: 1;
  padding: 0;
  line-height: 1;
}

.slide-btn.prev {
  left: 10px;
}

.slide-btn.next {
  right: 10px;
}

.slide-btn:hover {
  color: #6A5ACD;
}



/* Адаптивность */
@media (max-width: 600px) {
  nav ul {
    flex-direction: column;
  }

  .gallery {
    flex-direction: column;
    align-items: center;
  }

  .slider {
    width: 90%;
  }
}
