/* 定义CSS变量 */
:root {
  --banner-height: 400px;
  --section-padding: 40px;
  --title-font-size: 24px;
  --subtitle-font-size: 18px;
  --text-font-size: 16px;
  --small-font-size: 14px;
  --thumbnail-size: 100px;
  --gallery-gap: 30px;
  --main-image-size: 670px;
  --content-padding: 10%;
  --accent-color: #ff8500;
}

/* Banner样式 */
.product-banner {
  position: relative;
  width: 100%;
  height: var(--banner-height);
  overflow: hidden;
  margin-bottom: 40px;
}

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

/* 产品详情内容区域 */
.product-detail {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 80px;
  padding: 0 var(--content-padding);
}

/* 缩略图列表区域 */
.product-gallery {
  width: var(--thumbnail-size);
  margin-right: var(--gallery-gap);
}

.thumbnail-container {
  position: relative;
  height: 450px;
  display: flex;
  flex-direction: column;
}

.thumbnail-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 30px;
  background: #f0f0f0;
  border: none;
  cursor: pointer;
  padding: 5px 0;
  transition: background 0.3s;
}

.thumbnail-nav:hover {
  background: #e0e0e0;
}

.thumbnail-nav svg {
  width: 20px;
  height: 20px;
  fill: #666;
}

.thumbnail-list {
  flex: 1;
  overflow: hidden;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #ccc #f0f0f0;
  padding: 10px 0;
}

.thumbnail {
  width: 100%;
  height: var(--thumbnail-size);
  border: 2px solid #f0f0f0;
  margin-bottom: 10px;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.3s;
}

.thumbnail.active {
  border-color: var(--accent-color);
}

.thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* 产品大图区域 */
.product-image-container {
  position: relative;
  width: var(--main-image-size);
  height: var(--main-image-size);
  background: #f8f8f8;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: zoom-in;
}

.image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#main-product-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.2s ease;
  will-change: transform;
}

/* 产品信息区域 */
.product-info {
  flex: 1;
  padding-left: 40px;
}

.product-title {
  font-size: var(--title-font-size);
  font-weight: 500;
  margin: 0 0 20px;
}

.product-meta {
  margin-top: 20px;
}

.meta-item {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
}

.meta-label {
  color: #666;
  margin-right: 5px;
}

.meta-value {
  font-weight: 500;
}

.contact {
  display: flex;
  align-items: center;
}

.contact svg {
  margin-right: 10px;
}

.phone-number {
  font-size: var(--text-font-size);
  font-weight: 500;
  color: #333;
}

/* 下一个产品链接 */
.next-product {
  display: flex;
  justify-content: flex-end;
  padding: 20px var(--content-padding);
}

.next-product-link {
  display: flex;
  align-items: center;
  color: #333;
  text-decoration: none;
  font-size: var(--text-font-size);
  transition: color 0.3s;
}

.next-product-link:hover {
  color: var(--accent-color);
}

.next-product-link svg {
  margin-left: 5px;
  fill: currentColor;
}

/* 产品详情信息区域 */
.product-details-section {
  padding: var(--section-padding) var(--content-padding) 60px;
}

.product-details-header {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding-bottom: 15px;
  margin-bottom: 20px;
}

.product-details-header svg {
  fill: var(--accent-color);
  margin-right: 10px;
}

.product-details-title {
  font-size: var(--subtitle-font-size);
  font-weight: 500;
  margin: 0;
}

/* 产品详情内容 */
.product-details-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.product-details-text {
  line-height: 1.6;
  color: #333;
  font-size: var(--text-font-size);
}

.product-details-text p {
  margin-bottom: 20px;
}

.product-details-text h3 {
  font-size: var(--subtitle-font-size);
  margin-bottom: 15px;
  color: #222;
  font-weight: 500;
}

.product-details-text ul {
  padding-left: 20px;
  margin-bottom: 20px;
}

.product-details-text li {
  margin-bottom: 8px;
}
.product-details-text p span{
  text-wrap-mode: wrap !important;
}
.product-details-text .highlight {
  color: var(--accent-color);
  font-weight: 500;
}

.product-details-image {
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-details-image img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* 产品规格表 */
.product-specs {
  margin-top: 40px;
}

.specs-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

.specs-table th,
.specs-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.specs-table th {
  background-color: #f8f8f8;
  font-weight: 500;
  color: #333;
}

.specs-table tr:hover {
  background-color: #f9f9f9;
}

/* 响应式样式 - 大屏幕 */
@media screen and (min-width: 1400px) {
  :root {
    --banner-height: 500px;
    --section-padding: 50px;
    --title-font-size: 28px;
    --subtitle-font-size: 20px;
    --text-font-size: 18px;
    --small-font-size: 16px;
    --thumbnail-size: 120px;
    --gallery-gap: 40px;
    --main-image-size: 750px;
  }
  
  .thumbnail-container {
    height: 500px;
  }
}

/* 响应式样式 */
@media screen and (max-width: 1200px) {
  :root {
    --banner-height: 350px;
    --section-padding: 35px;
    --title-font-size: 22px;
    --subtitle-font-size: 17px;
    --text-font-size: 15px;
    --small-font-size: 13px;
    --thumbnail-size: 90px;
    --gallery-gap: 25px;
    --main-image-size: 550px;
    --content-padding: 5%;
  }
  .product-info{
    padding-top: 60px;
  }
  .product-title{
    text-align: center;
  }
  .product-meta{
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
  }
  .product-details-content {
    gap: 25px;
  }
}

@media screen and (max-width: 992px) {
  :root {
    --banner-height: 300px;
    --section-padding: 30px;
    --title-font-size: 20px;
    --subtitle-font-size: 16px;
    --text-font-size: 14px;
    --small-font-size: 12px;
    --thumbnail-size: 80px;
    --gallery-gap: 20px;
    --main-image-size: 450px;
  }
  
  .product-detail {
    flex-direction: column;
  }
  
  .product-gallery {
    width: 100%;
    margin-right: 0;
    margin-bottom: 20px;
  }
  
  .thumbnail-container {
    height: auto;
    flex-direction: row;
  }
  
  .thumbnail-nav {
    width: 30px;
    height: 100px;
  }
  
  .thumbnail-prev svg {
    transform: rotate(90deg);
  }
  
  .thumbnail-next svg {
    transform: rotate(90deg);
  }
  
  .thumbnail-list {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    flex: 1;
    padding: 0 10px;
  }
  
  .thumbnail {
    min-width: var(--thumbnail-size);
    margin-bottom: 0;
    margin-right: 10px;
  }
  
  .product-image-container {
    width: 100%;
    max-width: var(--main-image-size);
    height: auto;
    aspect-ratio: 1 / 1;
    margin: 0 auto 30px;
  }
  
  .product-info {
    padding-left: 0;
  }

  .next-product {
    padding: 20px 5%;
  }
  
  .product-details-section {
    padding: 30px 5% 50px;
  }
  
  .product-details-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .product-details-image {
    order: -1;
  }
}

@media screen and (max-width: 768px) {
  :root {
    --banner-height: 250px;
    --section-padding: 25px;
    --title-font-size: 20px;
    --subtitle-font-size: 16px;
  }
  
  .product-banner {
    margin-bottom: 30px;
  }
  
  .product-title {
    margin-bottom: 15px;
  }
  
  #main-product-image {
    transition: none;
  }
  
  .specs-table th,
  .specs-table td {
    padding: 10px;
  }
}

@media screen and (max-width: 576px) {
  :root {
    --banner-height: 200px;
    --section-padding: 20px;
    --title-font-size: 18px;
    --subtitle-font-size: 15px;
    --text-font-size: 14px;
    --small-font-size: 12px;
    --thumbnail-size: 70px;
  }
  
  .product-banner {
    margin-bottom: 20px;
  }
  
  .product-image-container {
    pointer-events: none;
    cursor: default;
  }
  
  #main-product-image {
    transform: none !important;
  }

  .next-product {
    padding: 15px 5%;
  }
  
  .product-details-section {
    padding: 20px 5% 40px;
  }
  
  .product-details-title {
    font-size: 16px;
  }
  
  .thumbnail-nav {
    width: 25px;
    height: 70px;
  }
  
  .thumbnail-nav svg {
    width: 16px;
    height: 16px;
  }
  
  .specs-table {
    font-size: var(--small-font-size);
  }
  
  .specs-table th,
  .specs-table td {
    padding: 8px;
  }
}

@media screen and (max-width: 375px) {
  :root {
    --banner-height: 180px;
    --section-padding: 15px;
    --title-font-size: 16px;
    --subtitle-font-size: 14px;
    --text-font-size: 13px;
    --small-font-size: 11px;
    --thumbnail-size: 60px;
  }
  
  .product-details-header svg {
    width: 20px;
    height: 20px;
  }
} 