/* ══════════════════════════════════════════════════════
   product-page.css — ShadowStore product detail
   ══════════════════════════════════════════════════════ */

/* ── Product Detail Layout ───────────────────────────── */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 52px;
  padding-top: 28px;
  padding-bottom: 60px;
}

/* ── Image Column ────────────────────────────────────── */
.pd-images {}

.pd-main-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pd-main-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pd-thumbs {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}
.pd-thumb {
  width: 72px;
  height: 72px;
  border-radius: var(--radius);
  object-fit: cover;
  border: 2px solid var(--border);
  cursor: pointer;
  transition: border-color .2s;
  background: var(--surface);
}
.pd-thumb:hover { border-color: var(--accent); }

/* ── Info Column ─────────────────────────────────────── */
.pd-info { display: flex; flex-direction: column; gap: 0; padding-top: 8px; }

.pd-name {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 12px;
}

.pd-price {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 20px;
}

.pd-description {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 24px;
  font-size: .9rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ── Size Selector ───────────────────────────────────── */
.pd-sizes { margin-bottom: 24px; }

.pd-label {
  font-size: .85rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 10px;
}
.pd-label strong { color: var(--accent); }

.size-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.size-btn {
  min-width: 48px;
  height: 40px;
  padding: 0 14px;
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: .875rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
}
.size-btn:hover   { border-color: var(--accent); color: var(--accent); }
.size-btn.selected {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.size-message {
  font-size: .8rem;
  color: var(--accent);
  min-height: 20px;
}

/* ── Add to Cart form ────────────────────────────────── */
.pd-cart-form { margin-bottom: 12px; }

.qty-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.qty-row label {
  font-size: .85rem;
  color: var(--text-muted);
  font-weight: 500;
  white-space: nowrap;
}
.qty-input {
  width: 80px !important;
  text-align: center;
}

/* ── Reviews ─────────────────────────────────────────── */
.reviews-section {
  padding-bottom: 60px;
  max-width: 760px;
}

.reviews-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 24px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.review-write {
  padding: 24px;
  margin-bottom: 28px;
  background: var(--surface);
}
.review-write h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text);
}

.review-list { display: flex; flex-direction: column; gap: 14px; }

.review-item {
  padding: 18px 20px;
  background: var(--surface);
}

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  flex-wrap: wrap;
  gap: 6px;
}
.review-author  { font-weight: 600; font-size: .9rem; }
.review-date    { font-size: .78rem; color: var(--text-muted); }
.review-text    { font-size: .9rem; color: var(--text-muted); line-height: 1.6; margin-bottom: 12px; }

.review-footer  { display: flex; align-items: center; gap: 8px; }
.like-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: .8rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 4px;
}
.like-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 768px) {
  .product-detail {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 16px;
  }
  .pd-main-image { aspect-ratio: 4/3; }
}

/* ── Product category label ──────────────────────────── */
.pd-category {
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--accent);
  margin-bottom: 8px;
}

/* ── Active thumb ────────────────────────────────────── */
.pd-thumb.active-thumb { border-color: var(--accent); }
.pd-thumb { cursor: pointer; }

/* ── Main image: fade transition ─────────────────────── */
.pd-main-image img {
  transition: opacity .15s ease, transform .5s ease;
}

/* ── Main image: cursor + hover effects ──────────────── */
#mainImgWrap {
  cursor: zoom-in;
  position: relative;
}
#mainImgWrap:hover img { transform: scale(1.04); }

/* ── Zoom hint overlay ───────────────────────────────── */
.pd-zoom-hint {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0,0,0,.55);
  color: rgba(255,255,255,.9);
  font-size: .7rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 5px;
  opacity: 0;
  transition: opacity .2s;
  pointer-events: none;
}
#mainImgWrap:hover .pd-zoom-hint { opacity: 1; }

/* ── Image counter badge ─────────────────────────────── */
.pd-img-counter {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0,0,0,.55);
  color: rgba(255,255,255,.9);
  font-size: .72rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  display: none;
  align-items: center;
  pointer-events: none;
}

/* ── Lightbox ─────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.92);
  backdrop-filter: blur(6px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.lightbox.open {
  opacity: 1;
  pointer-events: all;
}

.lb-img-wrap {
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lb-img-wrap img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius-lg);
  box-shadow: 0 32px 80px rgba(0,0,0,.6);
  transition: opacity .2s ease;
}

.lb-close {
  position: absolute;
  top: 20px; right: 24px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.15);
  color: #fff;
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s;
  z-index: 10000;
}
.lb-close:hover { background: rgba(255,255,255,.2); }

.lb-nav {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.15);
  color: #fff;
  width: 50px; height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s;
  z-index: 10000;
}
.lb-nav:hover { background: rgba(255,255,255,.2); }
.lb-prev { left: 24px; }
.lb-next { right: 24px; }

.lb-counter {
  position: absolute;
  bottom: 20px; left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,.7);
  font-size: .85rem;
  font-weight: 500;
  background: rgba(0,0,0,.4);
  padding: 4px 14px;
  border-radius: 999px;
}

/* ── Reviews title count ─────────────────────────────── */
.reviews-count {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 6px;
}

/* ── Review avatar ───────────────────────────────────── */
.review-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: .875rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── Review stars ────────────────────────────────────── */
.review-stars { display: flex; gap: 1px; margin-top: 2px; }
.review-stars .star        { color: var(--border); font-size: .9rem; }
.review-stars .star.filled { color: #facc15; }
