/**
 * WooCommerce 产品详情页样式
 *
 * 使用 Swiper.js 实现图片滑动切换效果
 * 移动为先（Mobile First）设计
 */


/**
 * 布局
 */

 @media screen and (min-width:768px) {
  .vt-woo-container .vt-woocommerce-product-gallery {
    width: 50%;
    float: left;
  }
  .vt-woo-container .summary.entry-summary {
    width: 50%;
    float: right;
  }

}


/*****************************************************************************/


/* ==================== 产品图片区域整体包装器 ==================== */
.vt-woocommerce-product-gallery {
  margin-bottom: 30px;
}

/* ==================== 主图 Swiper - 固定 1:1 比例 ==================== */
.product-main-swiper {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  background: #f9f9f9;
  margin-bottom: 10px;
  position: relative;
}

.product-main-swiper .swiper-slide {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f9f9f9;
}

.product-main-swiper .swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==================== 主图导航按钮 ==================== */
.product-main-swiper .swiper-button-prev,
.product-main-swiper .swiper-button-next {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.product-main-swiper .swiper-button-prev::after,
.product-main-swiper .swiper-button-next::after {
  font-size: 18px;
  color: #6366f1;
  font-weight: bold;
}

.product-main-swiper .swiper-button-prev {
  left: 15px;
}

.product-main-swiper .swiper-button-next {
  right: 15px;
}

/* 鼠标悬停时显示导航按钮 */
.product-main-swiper:hover .swiper-button-prev,
.product-main-swiper:hover .swiper-button-next {
  opacity: 1;
  visibility: visible;
}

/* 导航按钮悬停效果 */
.product-main-swiper .swiper-button-prev:hover,
.product-main-swiper .swiper-button-next:hover {
  background: rgba(255, 255, 255, 1);
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ==================== 缩略图 Swiper ==================== */
.product-thumb-swiper {
  width: 100%;
  height: auto;
  padding: 3px 0;
}

.product-thumb-swiper .swiper-wrapper {
  display: flex;
}

.product-thumb-swiper .swiper-slide {
  width: 70px;
  height: 70px;
  cursor: pointer;
  opacity: 0.6;
  transition: all 0.3s ease;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  flex-shrink: 0;
  background: #f9f9f9;
}

.product-thumb-swiper .swiper-slide:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.product-thumb-swiper .swiper-slide.swiper-slide-thumb-active {
  opacity: 1;
  border-color: #6366f1;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.product-thumb-swiper .swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==================== 平板端适配（min-width: 768px）==================== */
@media (min-width: 768px) {
  .vt-woocommerce-product-gallery {
    margin-bottom: 40px;
  }

  .product-main-swiper {
    border-radius: 12px;
    margin-bottom: 15px;
  }

  .product-thumb-swiper {
    padding: 5px 0;
  }

  .product-thumb-swiper .swiper-slide {
    width: 90px;
    height: 90px;
  }
}

/* ==================== 桌面端适配（min-width: 1024px）==================== */
@media (min-width: 1024px) {
  .product-thumb-swiper .swiper-slide {
    width: 100px;
    height: 100px;
  }
}


/*****************************************************************************/


/* ======================================
WooCommerce 产品右侧信息区样式
.summary.entry-summary 专用美化
====================================== */

/* 主容器 */
.summary.entry-summary {
  padding: 20px;
  box-sizing: border-box;
}

/* --------------------------
价格样式
-------------------------- */
.summary.entry-summary p.price {
  font-size: 24px;
  font-weight: 700;
  color: #e53935;
  margin: 0 0 20px 0;
}

/* 货币符号 */
.woocommerce-Price-currencySymbol {
  margin-right: 2px;
}

/* --------------------------
数量选择框
-------------------------- */
.summary .quantity {
  display: inline-block;
  vertical-align: top;
  margin-right: 10px;
  margin-bottom: 15px;
}

/* 数量输入框 */
.quantity input.qty {
  box-sizing: border-box;
  width: 80px !important;
  height: 48px;
  padding: 0 10px;
  margin: 0 15px 0 0;
  border: 1px solid #ddd;
  border-radius: 4px;
  text-align: center;
  font-size: 16px;
  transition: all 0.2s;
}

.quantity input.qty:focus {
  outline: none;
  border-color: #222;
}

/* --------------------------
加入购物车按钮
-------------------------- */
.single_add_to_cart_button.button.alt {
  height: 48px;
  line-height: 48px;
  padding: 0 30px;
  background-color: #222;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  display: inline-block;
  vertical-align: top;
}

.single_add_to_cart_button.button.alt:hover {
  background-color: #000;
  color: #fff;
}

/* --------------------------
产品分类 meta 信息
-------------------------- */
.product_meta {
  margin-top: 25px;
  padding-top: 15px;
  border-top: 1px dashed #eee;
  font-size: 14px;
  color: #666;
}

.product_meta a {
  color: #666;
  text-decoration: none;
  margin: 0 3px;
}

.product_meta a:hover {
  color: #222;
}

/* --------------------------
响应式：平板 & 电脑
移动优先（min-width）
-------------------------- */
@media (min-width: 768px) {
  .summary.entry-summary {
    padding: 30px 40px;
  }

  .summary p.price {
    font-size: 28px;
  }
}

@media (min-width: 992px) {
  .summary.entry-summary {
    padding: 40px 50px;
  }

  .summary p.price {
    font-size: 32px;
  }
}


/*****************************************************************************/
/*****************************************************************************/

/**
 * 相关文章
 */

.related.products {
  margin: 70px 0 30px 0;
}

@media screen and (min-width:768px) {
  .related.products {
    margin: 80px 0 30px 0;
  }
}



