/* Секция сторис под баннером */
.stories-section {
  width: 100%;
  background: #ffffff;
  padding: 30px 20px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  /* Скрываем scrollbar на мобильных */
  scrollbar-width: thin;
  scrollbar-color: rgba(236, 78, 15, 0.3) transparent;
}

.stories-section::-webkit-scrollbar {
  height: 4px;
}

.stories-section::-webkit-scrollbar-track {
  background: transparent;
}

.stories-section::-webkit-scrollbar-thumb {
  background: rgba(236, 78, 15, 0.3);
  border-radius: 2px;
}

.stories-section::-webkit-scrollbar-thumb:hover {
  background: rgba(236, 78, 15, 0.5);
}

.stories-container {
  display: flex;
  gap: 20px;
  justify-content: flex-start;
  align-items: center;
  max-width: 100%;
  padding: 0 10px;
  min-width: max-content;
}

.stories-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  cursor: pointer;
  transition: transform 0.2s ease;
  text-decoration: none;
  color: inherit;
  border: none;
  background: none;
  padding: 0;
  scroll-snap-align: start;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.stories-item:hover {
  transform: scale(1.05);
}

.stories-item:active {
  transform: scale(0.95);
}

.stories-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 3px solid #ec4e0f;
  overflow: hidden;
  position: relative;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(236, 78, 15, 0.2);
}

.stories-icon img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border-radius: 50%;
}

.stories-name {
  font-family: "Inter-Medium", sans-serif;
  font-size: 14px;
  line-height: 1.4;
  color: #000000;
  text-align: center;
  max-width: 90px;
  word-wrap: break-word;
  font-weight: 500;
}

/* Десктоп версия */
@media (min-width: 769px) {
  .stories-section {
    padding: 40px 60px;
    overflow-x: visible;
  }

  .stories-container {
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
  }

  .stories-icon {
    width: 100px;
    height: 100px;
    border-width: 4px;
  }

  .stories-name {
    font-size: 16px;
    max-width: 120px;
  }
}

/* Мобильная версия */
@media (max-width: 768px) {
  .stories-section {
    padding: 20px 10px;
  }

  .stories-container {
    gap: 15px;
    padding: 0 5px;
  }

  .stories-icon {
    width: 70px;
    height: 70px;
    border-width: 2.5px;
  }

  .stories-name {
    font-size: 12px;
    max-width: 80px;
  }
}