.profile-btn {
  position: absolute;
  right: 20px;
}

.fav-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.12s ease;
}

.fav-btn:active {
  transform: scale(0.96);
}

.fav-icon path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  transition: fill 0.18s ease, stroke 0.18s ease, transform 0.18s ease;
  color: #777;
  /* серый в пустом виде */
}

/* если в избранном — красное заполнение */
.fav-btn.active .fav-icon path {
  fill: currentColor;
  stroke: currentColor;
  color: #e0245e;
  transform: scale(1.02);
}

* {
  box-sizing: border-box;
}

body {
  font-family: "Inter", sans-serif;
}

.container {
  display: flex;
  padding: 20px;
  gap: 20px;
  flex-wrap: wrap;
}

.filter {
  width: 200px;
  background: #fff;
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.05);
  height: fit-content;
  position: sticky;
  top: 20px;
  flex-shrink: 0;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  flex: 1;
}

.card-people {
  background-color: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: fadeInUp 0.6s ease forwards;
  opacity: 0;
}

.card-people:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.photo-wrapper {
  position: relative;
}

.photo-wrapper img {
  display: block;
  width: 100%;
  height: auto;
}

.heart-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 24px;
  color: red;

  padding: 5px;
}

.heart-seri {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 24px;
  color: #ccc;
  border-radius: 50%;
  padding: 5px;
}

.user-info {
  display: flex;
  align-items: center;
  padding: 16px;
}

.user-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 16px;
  flex-shrink: 0;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-text {
  flex: 1;
}

.user-text .name {
  font-weight: bold;
  font-size: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.stars {
  color: #1e88e5;
}

.details {
  font-size: 14px;
  color: #333;
}

.rating {
  font-size: 14px;
  color: #333;
}

.rating .stars {
  font-size: 20px;
}

@media (max-width: 1024px) {
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .container {
    flex-direction: column;
  }

  .filter {
    width: 100%;
    position: relative;
  }

  .cards {
    grid-template-columns: 1fr;
  }

  .user-info {
    flex-direction: column;
    align-items: flex-start;
  }

  .user-avatar {
    margin-right: 0;
    margin-bottom: 10px;
  }
}

/* modal */
.container {
  padding-left: 15px;
  padding-right: 15px;
}

.card-body {
  padding: 20px;
}

.profile-photo {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
}

.profile-photo .heart,
.profile-photo .zoom,
.profile-photo .nav {
  position: absolute;

  color: white;
  padding: 6px 10px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 20px;
}

.heart {
  top: 10px;
  right: 10px;
  font-size: 24px;
  background: none;
  color: red;
}

.nav.left {
  top: 50%;
  left: 10px;
  transform: translateY(-50%);
}

.nav.right {
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
}

.zoom {
  bottom: 30px;
  left: 38px;
  font-size: 18px;
}

.name {
  font-weight: 600;
  font-size: 32px;
}

.rating-info-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 20px;
}

.rating-box {
  flex: 1 1 300px;
  padding-right: 20px;
  border-right: 1px solid #ccc;
}

.info-box {
  flex: 1 1 300px;
  padding-left: 20px;
  text-align: left;
  line-height: 31px;
}

.rating-row {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  font-size: 14px;
}

.rating-row input {
  margin-right: 6px;
  width: 14px;
  height: 14px;
}

.stars {
  width: 70px;
  color: #256dfd;
  margin-right: 8px;
}

.zvezda {
  color: #ccc;
}

/* Чтобы отзыв выглядел компактно */
.review-text {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  /* максимум 3 строки */
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bar {
  background-color: #e0e0e0;
  height: 8px;
  flex: 1;
  border-radius: 10px;
  overflow: hidden;
  margin-right: 8px;
}

.bar span {
  display: block;
  height: 100%;
  background-color: #256dfd;
}

.count {
  width: 30px;
  text-align: right;
}

.gallery {
  display: flex;
  overflow-x: auto;
  gap: 10px;
}

.gallery img {
  height: 80px;
  border-radius: 5px;
}

.btn {
  border-radius: 10px;
}

.btn i {
  margin-right: 5px;
}

@media (max-width: 768px) {
  .rating-box {
    border-right: none;
    border-bottom: 1px solid #ccc;
    padding-right: 0;
    padding-bottom: 15px;
  }

  .info-box {
    padding-left: 0;
    margin-top: 10px;
  }
}

.zvezda {
  color: #ccc;
}

.heart-icon button {}

.horizontal-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0 15px;
  margin: 0 -15px;
}

.horizontal-scroll::-webkit-scrollbar {
  height: 6px;
}

.horizontal-scroll::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.horizontal-scroll::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 3px;
}

.horizontal-scroll::-webkit-scrollbar-thumb:hover {
  background: #555;
}

.photo-cards {
  display: flex;
  gap: 15px;
  padding: 5px 0;
  min-width: max-content;
}

.photo-card {
  position: relative;
  width: 120px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.photo-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.photo-card:hover img {
  transform: scale(1.05);
}

.photo-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.photo-overlay svg {
  width: 22px;
  height: 22px;
  color: #fff;
  fill: #fff;
}

.photo-card:hover .photo-overlay {
  opacity: 1;
}

.photo-overlay i {
  color: white;
  font-size: 20px;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
  .photo-card {
    width: 100px;
    height: 70px;
  }

  .photo-cards {
    gap: 10px;
  }

  .horizontal-gallery {
    margin: 0 -10px;
  }

  .horizontal-scroll {
    padding: 0 10px;
    margin: 0 -10px;
  }
}

@media (max-width: 480px) {
  .photo-card {
    width: 80px;
    height: 60px;
  }

  .photo-cards {
    gap: 8px;
  }
}

/* Стили для сетки карточек пользователей */
.people-grid-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 20px;
  background: #2c2c2c;
  border-radius: 12px;
  margin: 20px 0;
}

.people-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
}

.people-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.card-photo-wrapper {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.card-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-heart-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
}

.card-heart-icon button {
  background: none;
  border: none;
  color: #dc3545;
  font-size: 18px;
  cursor: pointer;
  padding: 5px;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.card-heart-icon button:hover {
  transform: scale(1.1);
}

.card-heart-icon button.active {
  color: #dc3545;
}

.card-gallery-icon {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 10;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 12px;
}

.card-info {
  padding: 12px;
  background: white;
}

.card-name-line {
  margin-bottom: 6px;
  font-size: 14px;
  line-height: 1.3;
}

.card-username {
  font-weight: 600;
  color: #333;
}

.card-age {
  color: #666;
  margin: 0 5px;
}

.card-rating {
  color: #666;
  font-size: 12px;
}

.card-location {
  color: #888;
  font-size: 13px;
  line-height: 1.3;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 1200px) {
  .people-grid-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }
}

@media (max-width: 768px) {
  .people-grid-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 15px;
    margin: 15px 0;
  }

  .card-photo-wrapper {
    height: 180px;
  }

  .card-info {
    padding: 10px;
  }

  .card-name-line {
    font-size: 13px;
  }

  .card-location {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .people-grid-container {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 10px;
    margin: 10px 0;
  }

  .card-photo-wrapper {
    height: 150px;
  }

  .card-info {
    padding: 8px;
  }

  .card-name-line {
    font-size: 12px;
  }

  .card-location {
    font-size: 11px;
  }

  .card-heart-icon button {
    font-size: 16px;
  }
}

.stat-item {
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  margin-bottom: 10px;
  transition: all 0.3s ease;
}

.stat-item:hover {
  background: #e9ecef;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-number {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 5px;
}

.stat-label {
  font-size: 12px;
  color: #6c757d;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.activity-timeline {
  position: relative;
  padding-left: 30px;
}

.activity-timeline::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #dee2e6;
}

.activity-item {
  position: relative;
  margin-bottom: 20px;
  display: flex;
  align-items: flex-start;
}

.activity-icon {
  position: absolute;
  left: -23px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: white;
  z-index: 1;
}

.activity-content {
  background: #f8f9fa;
  padding: 12px 15px;
  border-radius: 8px;
  flex: 1;
  border-left: 3px solid #007bff;
}

.activity-title {
  font-weight: 600;
  color: #495057;
  margin-bottom: 4px;
}

.activity-time {
  font-size: 12px;
  color: #6c757d;
}

.info-section-divider {
  height: 2px;
  background: linear-gradient(to right, #007bff, #28a745);
  margin: 20px 0;
  border-radius: 1px;
}

.info-section-title {
  color: #495057;
  font-weight: 600;
  margin-bottom: 15px;
  padding: 10px 0;
  border-bottom: 2px solid #e9ecef;
}

.hashtags-section {
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  margin-bottom: 20px;
}

.hashtags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hashtag {
  background: #007bff;
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.hashtag:hover {
  background: #0056b3;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

/* Модалка / карусель */
.image-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn .12s ease;
}

.image-modal-content {
  position: relative;
  max-width: 92%;
  max-height: 92%;
  width: auto;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-modal-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
  border-radius: 6px;
}

/* Кнопки навигации */
.image-modal-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.4);
  border: none;
  color: #fff;
  font-size: 28px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background .12s ease, transform .08s ease;
}

.image-modal-btn:hover {
  background: rgba(0, 0, 0, 0.6);
  transform: translateY(-50%) scale(1.04);
}

.image-modal-prev {
  left: 18px;
}

.image-modal-next {
  right: 18px;
}

/* Закрыть */
.image-modal-close {
  position: absolute;
  top: 14px;
  right: 18px;
  font-size: 26px;
  background: rgba(0, 0, 0, 0.3);
  border: none;
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  cursor: pointer;
}

/* Счетчик */
.image-modal-counter {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  font-size: 14px;
  background: rgba(0, 0, 0, 0.25);
  padding: 6px 10px;
  border-radius: 12px;
}

/* Анимация */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Немного защиты для маленьких экранов */
@media (max-width: 480px) {
  .image-modal-btn {
    width: 40px;
    height: 40px;
    font-size: 22px;
  }

  .image-modal-close {
    width: 36px;
    height: 36px;
    font-size: 20px;
  }
}