.purchased-cars-section {
  background-color: #ffffff;
}

.purchased-cars-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 60px;
}

.purchased-cars-title {
  font-size: 48px;
  line-height: 1.25;
  font-weight: 700;
  color: #161c2d;
  text-align: center;
}

.cars-carousel {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 30px;
  position: relative;
}

.cars-list-wrapper {
  flex: 1;
  overflow-x: hidden;
}

.cars-list {
  display: flex;
  gap: 30px;
  transition: transform 0.3s ease;
}

.carousel-btn {
  background: transparent;
  border: none;
  padding: 0;
  width: 30.297px;
  height: 30.297px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #473bf0;
  transition: opacity 0.3s, transform 0.2s;
  cursor: pointer;
}

.carousel-btn:hover {
  transform: scale(1.1);
}

.carousel-btn:active {
  transform: scale(0.95);
}

.carousel-btn.disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.carousel-btn.disabled:hover {
  transform: scale(1);
}

.car-card {
  background-color: #ffffff;
  border: 1px solid #f4f7fa;
  border-radius: 5px;
  overflow: hidden;
  flex: 0 0 calc(25% - 22.5px);
  min-width: 0;
  display: flex;
  flex-direction: column;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
  text-decoration: none;
  color: inherit;
  box-sizing: border-box;
}

.car-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  text-decoration: none;
  color: inherit;
}

.car-image {
  width: 100%;
  height: 229px;
  overflow: hidden;
  background-color: #f4f7fa;
}

.car-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

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

.car-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #e9ecef;
  color: #6c757d;
  font-size: 16px;
}

.car-info {
  padding: 15px 0 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

.car-title {
  font-size: 24px;
  line-height: 1.25;
  font-weight: 700;
  color: #161c2d;
  text-align: center;
  margin: 0;
}

.car-year {
  font-size: 17px;
  line-height: 1.25;
  font-weight: 400;
  color: #161c2d;
  opacity: 0.7;
  text-align: center;
  margin: 0;
}

.car-price {
  font-size: 26px;
  line-height: normal;
  font-weight: 800;
  color: #666666;
  text-align: center;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin: 0;
}

.car-city {
  font-size: 14px;
  color: #6c757d;
  text-align: center;
  margin: 0;
  font-style: italic;
}

.view-all-btn {
  background-color: #f64b4b;
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 13px 40px;
  font-size: 17px;
  line-height: 1.25;
  font-weight: 700;
  text-align: center;
  transition: background-color 0.3s, transform 0.2s;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}

.view-all-btn:hover {
  background-color: #e43939;
  transform: translateY(-2px);
  color: #ffffff;
  text-decoration: none;
}

.view-all-btn:active {
  transform: translateY(0);
}

@media (max-width: 1200px) {
  .purchased-cars-title {
    font-size: 40px;
  }

  .cars-list {
    gap: 20px;
  }

  .cars-carousel {
    gap: 20px;
  }

  .car-card {
    flex: 0 0 calc(33.333% - 14px);
  }
}

@media (max-width: 992px) {
  .purchased-cars-section {
    padding: 60px 20px;
  }

  .purchased-cars-container {
    gap: 40px;
  }

  .purchased-cars-title {
    font-size: 36px;
  }

  .car-card {
    flex: 0 0 calc(50% - 15px);
  }

  .cars-carousel {
    gap: 15px;
  }
}

@media (max-width: 768px) {
  .purchased-cars-title {
    font-size: 32px;
  }

  .car-image {
    height: 200px;
  }

  .car-title {
    font-size: 20px;
  }

  .car-year {
    font-size: 15px;
  }

  .car-price {
    font-size: 22px;
  }

  .view-all-btn {
    padding: 12px 30px;
    font-size: 16px;
  }

  .cars-carousel {
    gap: 10px;
  }

  .carousel-btn {
    width: 25px;
    height: 25px;
  }
}

@media (max-width: 600px) {
  .purchased-cars-section {
    padding: 40px 15px;
  }

  .purchased-cars-title {
    font-size: 28px;
  }

  .car-card {
    flex: 0 0 100%;
  }

  .car-image {
    height: 180px;
  }

  .car-info {
    padding: 12px 0 20px;
    gap: 12px;
  }

  .car-title {
    font-size: 18px;
  }

  .car-year {
    font-size: 14px;
  }

  .car-price {
    font-size: 20px;
  }

  .view-all-btn {
    padding: 10px 25px;
    font-size: 15px;
  }

  .cars-list {
    gap: 15px;
  }

  .cars-carousel {
    gap: 8px;
  }

  .carousel-btn {
    width: 20px;
    height: 20px;
  }
}

@media (max-width: 360px) {
  .car-image {
    height: 160px;
  }

  .purchased-cars-title {
    font-size: 24px;
  }
}
