/* Frontend CSS for WIA Custom Sections */

/* Common styles for all sections */
.wia-section {
  margin: 30px 0;
  padding: 20px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
  position: relative;
}

.wia-section h3 {
  font-size: 20px;
  color: #8a2be2;
  margin-bottom: 15px;
  text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.8);
  position: relative;
  display: inline-block;
}

.wia-section h3:after {
  content: "";
  display: block;
  width: 40px;
  height: 2px;
  background: #fb6e2e;
  margin-top: 5px;
  transition: width 0.3s ease;
}

.wia-section:hover h3:after {
  width: 100%;
}

/* Our Services section styles */
.our-services .service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.our-services .service-box {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.our-services .service-box:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.our-services .service-box:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(to right, #8a2be2, #fb6e2e);
  transform: scaleX(0);
  transform-origin: 0 0;
  transition: transform 0.5s ease;
}

.our-services .service-box:hover:before {
  transform: scaleX(1);
}

.our-services .service-icon {
  font-size: 40px;
  color: #8a2be2;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

.our-services .service-box:hover .service-icon {
  transform: scale(1.1);
  color: #fb6e2e;
}

.our-services .service-title {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #333;
  transition: all 0.3s ease;
}

.our-services .service-box:hover .service-title {
  color: #8a2be2;
}

.our-services .service-description {
  font-size: 14px;
  color: #666;
  margin-bottom: 10px;
}

.our-services .service-link {
  display: inline-block;
  padding: 5px 15px;
  background: rgba(138, 43, 226, 0.1);
  color: #8a2be2;
  border-radius: 5px;
  font-size: 13px;
  transition: all 0.3s ease;
}

.our-services .service-link:hover {
  background: #8a2be2;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 3px 5px rgba(138, 43, 226, 0.2);
}

/* Why Choose Us section styles */
.why-choose-us {
  margin-top: 30px;
  margin-bottom: 30px;
  padding: 30px;
}

.features-container {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.feature-box {
  display: flex;
  align-items: flex-start;
  transition: all 0.3s ease;
  padding: 15px;
  border-radius: 8px;
  background: #f9f9fb;
}

.feature-box:hover {
  transform: translateX(5px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  background: #fff;
}

.feature-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #8a2be2, #fb6e2e);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 15px;
  color: #fff;
  font-size: 18px;
  transition: all 0.3s ease;
}

.feature-box:hover .feature-icon {
  transform: rotate(360deg);
  box-shadow: 0 0 10px rgba(138, 43, 226, 0.5);
}

.feature-content {
  flex: 1;
}

.feature-title {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 5px;
  color: #333;
}

.feature-description {
  font-size: 14px;
  color: #666;
}

/* Reviews section styles */
.featured-reviews .reviews-slider {
  margin-top: 20px;
}

.featured-reviews .review-item {
  background: #fff;
  border-radius: 10px;
  padding: 15px;
  margin: 10px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.featured-reviews .review-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.featured-reviews .review-header {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.featured-reviews .review-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 10px;
}

.featured-reviews .review-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.featured-reviews .review-info {
  flex: 1;
}

.featured-reviews .review-name {
  font-weight: bold;
  margin-bottom: 2px;
  color: #333;
}

.featured-reviews .review-date {
  font-size: 12px;
  color: #999;
}

.featured-reviews .review-stars {
  color: #ffd700;
  margin-bottom: 10px;
}

.featured-reviews .star-filled {
  margin-right: 2px;
}

.featured-reviews .star-empty {
  margin-right: 2px;
  color: #ddd;
}

.featured-reviews .review-content {
  font-size: 14px;
  line-height: 1.5;
  color: #555;
  margin-bottom: 10px;
}

.featured-reviews .review-product {
  display: flex;
  align-items: center;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed #eee;
}

.featured-reviews .review-product-img {
  width: 50px;
  margin-right: 10px;
}

.featured-reviews .review-product-img img {
  width: 100%;
  height: auto;
  border-radius: 5px;
}

.featured-reviews .review-product-name {
  font-size: 13px;
  color: #8a2be2;
}

/* Recently Viewed Products styles */
.huan-recently-viewed {
  padding: 15px;
}

.wia-recently-viewed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}

.wia-recently-viewed-list .recently-viewed-item {
  display: flex;
  margin-bottom: 15px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.wia-recently-viewed-list .product-image {
  width: 100px;
  margin-right: 15px;
}

.wia-recently-viewed-list .product-details {
  flex: 1;
}

.recently-viewed-item {
  margin-bottom: 20px;
  transition: all 0.3s ease;
}

.recently-viewed-item:hover {
  transform: translateY(-5px);
}

.recently-viewed-item .product-image {
  margin-bottom: 10px;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.recently-viewed-item .product-image img {
  width: 100%;
  height: auto;
  transition: all 0.3s ease;
}

.recently-viewed-item:hover .product-image img {
  transform: scale(1.05);
}

.recently-viewed-item .product-title {
  font-size: 15px;
  margin-bottom: 5px;
}

.recently-viewed-item .product-title a {
  color: #333;
  text-decoration: none;
}

.recently-viewed-item:hover .product-title a {
  color: #8a2be2;
}

.recently-viewed-item .product-price {
  margin-bottom: 10px;
  color: #fb6e2e;
  font-weight: bold;
}

.recently-viewed-item .product-add-to-cart .button {
  background: #8a2be2;
  color: #fff;
  border: none;
  padding: 5px 10px;
  border-radius: 3px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.recently-viewed-item .product-add-to-cart .button:hover {
  background: #fb6e2e;
}

/* Responsive styles */
@media (max-width: 992px) {
  .our-services .service-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .our-services .service-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .wia-recently-viewed-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .wia-section h3 {
    font-size: 18px;
  }
}

@media (max-width: 576px) {
  .our-services .service-grid {
    grid-template-columns: 1fr;
  }

  .wia-recently-viewed-grid {
    grid-template-columns: 1fr;
  }

  .wia-section {
    padding: 15px;
  }

  .wia-recently-viewed-list .recently-viewed-item {
    flex-direction: column;
  }

  .wia-recently-viewed-list .product-image {
    width: 100%;
    margin-right: 0;
    margin-bottom: 10px;
  }
}
