html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #F5F5F5;
}

/* Заголовки */
.subtitle-css {
  font-weight: 600;
  font-size: 1.1rem;
  width: fit-content;
  padding: 0.3em 0.6em;
  border-radius: 20px;
  background-color: transparent;
  box-shadow: inset 2px 2px 6px rgba(0,0,0,0.2),
              inset -2px -2px 6px rgba(255,255,255,0.4);
}

.card h4 {
  font-weight: bold;
  font-size: 1.1rem;
}

.small-option {
  font-size: 1rem;
  padding: 0.3rem 0.6rem;
  border-radius: 20px;
  white-space: nowrap;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* --- Слайдер --- */
.slide {
  position: relative;
  background-size: cover;
  background-position: center;
  width: 100%;
  min-height: 300px;
  border-radius: 20px;
  margin-bottom: 16px;
  overflow: hidden;
  color: white;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  display: none;
}
.slide.active {
  display: block;
  opacity: 1;
}

.gradient-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.5) 60%);
  z-index: 1;
}

.slide-content {
  z-index: 2; /* чтобы контент был поверх градиента */
}

.slide-content {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 12px;
}

 .slide-content .left-text {
  max-width: 70%;
}

.slide-content h2 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.slide-content p.description {
  font-size: 0.85rem;
  line-height: 1.4;
  margin-bottom: 0;
}

.slide-content .right-controls {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  width: 30%;
}

.subtitle, .title, .description {
  font-size: 0.9rem;
  color: white;
}

/* Кнопки */
.btn-light {
  background-color: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  color: white;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 20px;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.4rem 0.7rem;
  box-shadow: inset 2px 2px 6px rgba(0,0,0,0.25),
              inset -2px -2px 6px rgba(255,255,255,0.25),
              0 0 8px rgba(255,255,255,0.3);
  transition: all 0.3s ease;
}
.btn-light:hover {
  background-color: rgba(255, 255, 255, 0.2);
  box-shadow: inset 1px 1px 4px rgba(0,0,0,0.2),
              inset -1px -1px 4px rgba(255,255,255,0.2),
              0 0 10px rgba(255,255,255,0.4);
}

/* Индикаторы слайдера */
.segments-bar {
  position: absolute;
  bottom: 8px;
  left: 12px;
  right: 12px;
  display: flex;
  gap: 4px;
  z-index: 3;
}
.segment {
  flex: 1;
  height: 5px;
  background: rgba(255,255,255,0.3);
  border-radius: 3px;
  position: relative;
}
.segment::before {
  content: '';
  position: absolute;
  inset: 0;
  width: 0%;
  background-color: rgba(255,255,255,0.8);
  transition: width 2.5s linear;
  border-radius: 3px;
}
.segment.active::before {
  width: 100%;
}

/* --- Хедер и футер --- */
.site-header {
  background-color: #f5f5f5;
  border-bottom: 1px solid #ccc;
  padding: 8px;
}

.site-footer {
  background-color: #141414;
  color: white;
  padding: 12px;
  text-align: center;
}

.footer_icon {
  width: 44px;
  height: 44px;
  background-color: transparent;
  border-radius: 50%;
  box-shadow: inset 2px 2px 6px rgba(0,0,0,0.2),
              inset -2px -2px 6px rgba(255,255,255,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

/* --- Сетка картинок --- */
.image-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  padding: 0 10px;
}

.image-grid img {
  width: 100%;
  max-width: 90%;
  height: auto;
  border-radius: 24px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* --- Адаптация для мобильных устройств --- */
@media (max-width: 576px) {
  .slide {
    min-height: 300px;
    border-radius: 16px;
  }

  .btn-light {
    font-size: 0.85rem;
    padding: 0.3rem 0.6rem;
  }

  .subtitle-css {
    font-size: 0.95rem;
    padding: 0.2em 0.5em;
  }

  .card h4 {
    font-size: 1rem;
  }

  .image-grid {
    padding: 0 6px;
    gap: 12px;
  }

  .image-grid img {
    max-width: 100%;
    border-radius: 16px;
  }

  .site-header, .site-footer {
    padding: 6px;
  }

  .footer_icon {
    width: 36px;
    height: 36px;
  }
  

  .slide-content {
    flex-direction: column;
    align-items: flex-start;
  }

  .slide-content .left-text,
  .slide-content .right-controls {
    width: 100%;
  }

  .slide-content h2 {
    font-size: 1rem;
  }

  .slide-content p.description {
    font-size: 0.8rem;
  }

  input[type="radio"]:checked + label,
  input[type="checkbox"]:checked + label {
    background-color: #0078d4;
    color: white;
    transition: all 0.3s ease;
  }
}
