/* 产品详情弹窗 */
.product-modal,
.product-modal *,
.product-modal *::before,
.product-modal *::after {
  box-sizing: border-box;
}

.product-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.product-modal.is-open {
  display: flex;
}

.product-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 18, 22, 0.55);
  animation: productModalFadeIn 0.2s ease;
}

.product-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(880px, 100%);
  max-height: 90vh;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18);
  overflow: auto;
  animation: productModalSlideUp 0.25s ease;
}

.product-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.product-modal__close:hover {
  background: #f0f2f4;
}

.product-modal__close span {
  position: absolute;
  width: 16px;
  height: 2px;
  background: #5a6570;
  border-radius: 1px;
}

.product-modal__close span:first-child {
  transform: rotate(45deg);
}

.product-modal__close span:last-child {
  transform: rotate(-45deg);
}

.product-modal__content {
  padding: 28px 56px 28px 28px;
}

.product-modal__head {
  margin: 0 0 24px;
  padding: 0;
}

.product-modal__category {
  margin: 0 0 8px;
  font-family: "Roboto", sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #8a939e;
  letter-spacing: 0.02em;
  line-height: 1.4;
}

.product-modal__title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0;
}

.product-modal__title-row h2 {
  margin: 0;
  padding: 0;
  color: #69512d;
  font-family: "Roboto", sans-serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.3;
}

.product-modal__badge {
  padding: 4px 10px;
  border-radius: 4px;
  background: #69512d;
  color: #fff;
  font-family: "Roboto", sans-serif;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  white-space: nowrap;
}

.product-modal__badge:empty {
  display: none;
}

.product-modal__main {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 24px;
  align-items: stretch;
}

.product-modal__media {
  position: relative;
  min-height: 320px;
  height: 100%;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e4e8ec;
  border-radius: 8px;
  background: #fff;
}

.product-modal__media img {
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
  object-position: center;
  display: block;
}

.product-modal__specs {
  display: flex;
  flex-direction: column;
  border: 1px solid #e4e8ec;
  border-radius: 8px;
  overflow: hidden;
}

.product-modal__spec {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 12px;
  align-items: center;
  padding: 12px 16px;
  margin: 0;
  background: #fff;
  border-bottom: 1px solid #e4e8ec;
}

.product-modal__spec:last-child {
  border-bottom: 0;
}

.product-modal__spec:nth-child(even) {
  background: #f8f9fa;
}

.product-modal__spec.full {
  grid-template-columns: 1fr;
  align-items: start;
  gap: 6px;
}

.product-modal__spec-label {
  margin: 0;
  font-family: "Roboto", sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: #6b7785;
  line-height: 1.4;
}

.product-modal__spec-value {
  margin: 0;
  font-family: "Roboto", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #2d3740;
  line-height: 1.4;
  word-break: break-word;
}

.product-modal__section {
  margin: 24px 0 0;
  padding: 0;
}

.product-modal__section[hidden] {
  display: none !important;
}

.product-modal__section-title {
  margin: 0 0 12px;
  padding: 0;
  font-family: "Roboto", sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #354452;
  line-height: 1.4;
}

.product-modal__tags {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.product-modal__tags li {
  margin: 0;
  padding: 6px 12px;
  border-radius: 6px;
  background: #f4f6f8;
  color: #515e6e;
  font-family: "Roboto", sans-serif;
  font-size: 13px;
  line-height: 1.4;
}

.product-modal__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 28px 0 0;
  padding: 24px 0 0;
  border-top: 1px solid #e4e8ec;
}

.product-modal__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 20px;
  border-radius: 8px;
  font-family: "Roboto", sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
  cursor: pointer;
}

.product-modal__cta.primary {
  background: #2d2d2d;
  border: 2px solid #2d2d2d;
  color: #fff !important;
}

.product-modal__cta.primary:hover {
  background: #69512d;
  border-color: #69512d;
}

.product-modal__cta.whatsapp {
  background: #25d366;
  border: 2px solid #25d366;
  color: #fff !important;
  gap: 8px;
}

.product-modal__cta.whatsapp:hover {
  background: #1da851;
  border-color: #1da851;
}

.product-modal__whatsapp-icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  display: block;
}

#product_002 .list .item a {
  cursor: pointer;
  transition: transform 0.2s ease;
}

#product_002 .list .item a:hover {
  transform: translateY(-3px);
}

@keyframes productModalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes productModalSlideUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .product-modal {
    padding: 12px;
  }

  .product-modal__content {
    padding: 24px 48px 24px 20px;
  }

  .product-modal__main {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .product-modal__media {
    min-height: 260px;
  }

  .product-modal__media img {
    min-height: 260px;
  }

  .product-modal__title-row h2 {
    font-size: 20px;
  }

  .product-modal__spec {
    grid-template-columns: 108px 1fr;
    gap: 10px;
    padding: 10px 14px;
  }

  .product-modal__actions {
    grid-template-columns: 1fr;
  }
}
