/* Product detail page */
.product-gallery-main {
  border-radius: 12px;
  overflow: hidden;
  background: #f3f5f7;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.product-gallery-empty {
  min-height: 280px;
  color: #8a939c;
  font-size: 0.95rem;
}

.product-gallery-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.product-gallery-thumb {
  width: 72px;
  height: 72px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: #f3f5f7;
  cursor: pointer;
  transition: border-color 0.2s ease, opacity 0.2s ease;
}

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

.product-gallery-thumb:hover,
.product-gallery-thumb.is-active {
  border-color: var(--tj-theme-primary, #c8102e);
}

.product-detail-title {
  font-size: clamp(1.6rem, 2.4vw, 2.2rem);
  margin: 0 0 1rem;
  line-height: 1.25;
}

.product-detail-excerpt {
  color: var(--tj-color-text-body, #5c6770);
  line-height: 1.7;
  margin-bottom: 1.5rem;
  white-space: pre-line;
}

.product-detail-actions {
  margin-top: 0.5rem;
}

/* Fix CKEditor lists stacking vertically (blog uses 2 columns) */
.product-detail-content {
  max-width: 920px;
}

.product-detail-content > * {
  display: block;
  width: 100%;
  max-width: 100%;
}

.product-detail-content p,
.product-detail-content h1,
.product-detail-content h2,
.product-detail-content h3,
.product-detail-content h4,
.product-detail-content h5,
.product-detail-content h6,
.product-detail-content ul,
.product-detail-content ol,
.product-detail-content blockquote,
.product-detail-content figure,
.product-detail-content table {
  display: block;
  width: 100%;
  max-width: 100%;
  margin-top: 0;
  margin-bottom: 1rem;
}

.product-detail-content ul,
.product-detail-content ol {
  columns: auto !important;
  -webkit-columns: auto !important;
  -moz-columns: auto !important;
  list-style-position: outside;
  padding-left: 1.25rem;
}

.product-detail-content ul li,
.product-detail-content ol li {
  display: list-item !important;
  margin-bottom: 0.5rem;
  break-inside: avoid;
}

.product-detail-content img {
  max-width: 100%;
  height: auto;
}

.product-other-section {
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.product-other-card .project-img {
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.product-other-card .project-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 991px) {
  .product-detail-summary {
    margin-top: 0.5rem;
  }
}
