/* ============================================
   Chanren - Single Product Page (Chooetle-style)
   ============================================ */

.chanren-product {
  background: var(--cr-bg, #0d0d0d);
  color: var(--cr-text, #e0e0e0);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  padding-bottom: 60px;
  min-height: 100vh;
}

.cp-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 20px 0;
}

/* Breadcrumb */
.cp-breadcrumb {
  font-size: 0.8rem;
  color: var(--cr-muted, #999);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.cp-breadcrumb a {
  color: var(--cr-muted, #999);
  text-decoration: none;
  transition: color 0.2s ease;
}
.cp-breadcrumb a:hover { color: #fff; }
.cp-breadcrumb__current { color: #ccc; }

/* Top layout */
.cp-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
  margin-bottom: 48px;
}

/* ---- Gallery ---- */
.cp-gallery__main {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #2a2a2a;
  background: #161616;
  margin-bottom: 12px;
}
.cp-gallery__main img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.cp-gallery__main:hover img { transform: scale(1.03); }
.cp-gallery__badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  background: var(--cr-red, #e53935);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cp-gallery__zoom {
  position: absolute;
  bottom: 14px;
  right: 14px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #333;
  background: rgba(20,20,20,0.85);
  color: #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.cp-gallery__zoom svg { width: 18px; height: 18px; }
.cp-gallery__zoom:hover { background: var(--cr-red, #e53935); color: #fff; border-color: var(--cr-red, #e53935); }

.cp-gallery__thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
  padding-bottom: 4px;
}
.cp-gallery__thumb {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  opacity: 0.55;
  flex-shrink: 0;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}
.cp-gallery__thumb:hover { opacity: 0.9; }
.cp-gallery__thumb.active { opacity: 1; border-color: var(--cr-red, #e53935); }

/* ---- Buy Box ---- */
.cp-buybox__title {
  font-size: 1.6rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  margin-bottom: 8px;
}
.cp-buybox__sku {
  font-size: 0.78rem;
  color: var(--cr-muted, #999);
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}
.cp-buybox__prices {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.cp-buybox__sale {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--cr-red, #e53935);
}
.cp-buybox__reg {
  font-size: 1.05rem;
  color: var(--cr-muted, #999);
  text-decoration: line-through;
}
.cp-buybox__save {
  background: var(--cr-red, #e53935);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 3px;
  text-transform: uppercase;
}
.cp-buybox__desc {
  color: var(--cr-muted, #999);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 22px;
  border-left: 3px solid var(--cr-gold, #d4a843);
  padding-left: 14px;
}

/* Options */
.cp-option { margin-bottom: 20px; }
.cp-option__label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #ccc;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}
.cp-option__label span { color: var(--cr-gold, #d4a843); text-transform: none; letter-spacing: 0; }

/* Color swatches */
.cp-swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.cp-swatch {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2px solid #333;
  background: var(--swatch, #888);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.cp-swatch:hover { transform: scale(1.1); }
.cp-swatch.active {
  border-color: #fff;
  box-shadow: 0 0 0 2px var(--cr-red, #e53935);
}
.cp-swatch__label {
  position: absolute;
  bottom: -20px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.62rem;
  color: var(--cr-muted, #999);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.cp-swatch:hover .cp-swatch__label,
.cp-swatch.active .cp-swatch__label { opacity: 1; }

/* Quantity */
.cp-qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid #333;
  border-radius: 6px;
  overflow: hidden;
}
.cp-qty__btn {
  width: 44px;
  height: 44px;
  background: #1c1c1c;
  color: #fff;
  border: none;
  font-size: 1.3rem;
  cursor: pointer;
  transition: background 0.2s ease;
}
.cp-qty__btn:hover { background: var(--cr-red, #e53935); }
.cp-qty input {
  width: 56px;
  height: 44px;
  text-align: center;
  background: #111;
  color: #fff;
  border: none;
  border-left: 1px solid #333;
  border-right: 1px solid #333;
  font-size: 1rem;
  font-weight: 600;
}

/* CTA buttons */
.cp-btn {
  display: block;
  width: 100%;
  padding: 15px;
  border: none;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.25s ease;
  margin-bottom: 10px;
}
.cp-btn--cart {
  background: var(--cr-red, #e53935);
  color: #fff;
  box-shadow: 0 4px 16px rgba(229,57,53,0.25);
}
.cp-btn--cart:hover {
  background: #c62828;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(229,57,53,0.4);
}
.cp-btn--buy {
  background: transparent;
  color: #fff;
  border: 2px solid #fff;
}
.cp-btn--buy:hover { background: #fff; color: #0d0d0d; }
.cp-btn--sm { padding: 12px 24px; margin: 0; width: auto; }
.cp-buybox__more {
  text-align: center;
  font-size: 0.75rem;
  color: var(--cr-muted, #999);
  margin-top: 6px;
}

/* Trust badges */
.cp-trust {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 22px 0;
}
.cp-trust__item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #161616;
  border: 1px solid #262626;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 0.78rem;
  color: #ccc;
  transition: border-color 0.2s ease;
}
.cp-trust__item:hover { border-color: var(--cr-gold, #d4a843); }
.cp-trust__item svg {
  width: 22px;
  height: 22px;
  color: var(--cr-gold, #d4a843);
  flex-shrink: 0;
}

/* Share */
.cp-share {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 18px;
  border-top: 1px solid #262626;
}
.cp-share__label { font-size: 0.78rem; color: var(--cr-muted, #999); }
.cp-share__link {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #1c1c1c;
  border: 1px solid #333;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ccc;
  transition: all 0.2s ease;
}
.cp-share__link svg { width: 15px; height: 15px; }
.cp-share__link:hover { background: var(--cr-red, #e53935); color: #fff; border-color: var(--cr-red, #e53935); transform: translateY(-2px); }

/* ---- Details accordion ---- */
.cp-details {
  background: #141414;
  border: 1px solid #262626;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 48px;
}
.cp-details__toggle {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px;
  background: #1a1a1a;
  border: none;
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.cp-details__toggle svg {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease;
}
.cp-details.open .cp-details__toggle svg { transform: rotate(180deg); }
.cp-details__body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s ease;
}
.cp-details.open .cp-details__body { max-height: 8000px; }
.cp-details__body > * { margin: 0 24px; }
.cp-details__body { padding: 0 0 24px; }
.cp-details__body p, .cp-details__body h3, .cp-details__body h2,
.cp-details__body ul, .cp-details__body table, .cp-details__body blockquote,
.cp-details__body .cp-shipbox, .cp-details__body .cp-reasons, .cp-details__body hr {
  margin-left: 24px;
  margin-right: 24px;
}

.cp-guarantee {
  list-style: none;
  padding: 20px 24px 0;
  color: #ccc;
  font-size: 0.88rem;
  line-height: 2;
}
.cp-guarantee li::before { content: "✓ "; color: var(--cr-green, #43a047); font-weight: 700; }

.cp-divider { border: none; border-top: 1px solid #2a2a2a; margin-top: 24px; margin-bottom: 24px; }

.cp-lead { font-size: 1.05rem; color: #fff; }
.cp-details__body p { color: #bbb; font-size: 0.9rem; line-height: 1.8; margin-bottom: 14px; }

.cp-h { color: #fff; font-size: 1.15rem; font-weight: 700; margin-bottom: 12px; }
.cp-h--lg { font-size: 1.4rem; }
.cp-ideal { color: var(--cr-gold, #d4a843) !important; font-weight: 600; font-size: 0.85rem !important; }

/* Specs table */
.cp-specs {
  width: calc(100% - 48px);
  border-collapse: collapse;
  margin-bottom: 16px;
  font-size: 0.88rem;
}
.cp-specs th {
  background: #1e1e1e;
  color: var(--cr-gold, #d4a843);
  text-align: left;
  padding: 12px 16px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 2px solid var(--cr-red, #e53935);
}
.cp-specs td {
  padding: 11px 16px;
  border-bottom: 1px solid #262626;
  color: #bbb;
}
.cp-specs tr:hover td { background: #1a1a1a; }
.cp-specs td strong { color: #fff; font-weight: 600; }

.cp-note {
  border-left: 3px solid var(--cr-gold, #d4a843);
  background: #1a1a1a;
  padding: 12px 16px;
  color: var(--cr-muted, #999);
  font-size: 0.8rem;
  font-style: italic;
  margin-bottom: 16px;
}

/* Shipping box */
.cp-shipbox {
  background: #1a1a1a;
  border: 1px dashed var(--cr-gold, #d4a843);
  border-radius: 8px;
  padding: 24px;
  margin-top: 24px;
  margin-bottom: 24px;
  text-align: center;
}
.cp-shipbox__title { color: var(--cr-red, #e53935); font-size: 1.2rem; font-weight: 800; margin: 14px 0 10px; }
.cp-shipbox p { color: #ccc !important; line-height: 2 !important; }

/* Reasons */
.cp-reasons {
  background: #161616;
  border: 1px solid #262626;
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 24px;
}
.cp-reasons__title {
  color: #fff;
  font-size: 1.1rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 20px;
  letter-spacing: 0.04em;
}
.cp-reasons__item {
  display: flex;
  gap: 14px;
  margin-bottom: 16px;
  font-size: 0.85rem;
  color: #bbb;
  line-height: 1.6;
}
.cp-reasons__item span { font-size: 1.3rem; flex-shrink: 0; }
.cp-reasons__item strong { color: #fff; }

.cp-disclaimer {
  font-size: 0.75rem !important;
  color: var(--cr-muted, #999) !important;
  text-align: center;
  letter-spacing: 0.03em;
  margin-top: 24px;
}

/* ---- Related ---- */
.cp-related__title {
  color: #fff;
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 24px;
}
.cp-related__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.cp-related__card {
  background: #161616;
  border: 1px solid #262626;
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.cp-related__card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,0.5); }
.cp-related__img { position: relative; }
.cp-related__img img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.cp-related__badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--cr-red, #e53935);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 3px;
}
.cp-related__name {
  color: #ccc;
  font-size: 0.82rem;
  padding: 12px 14px 6px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cp-related__price { padding: 0 14px 14px; display: flex; gap: 8px; align-items: center; }
.cp-related__sale { color: var(--cr-red, #e53935); font-weight: 700; font-size: 1rem; }
.cp-related__reg { color: var(--cr-muted, #999); text-decoration: line-through; font-size: 0.78rem; }

/* ---- Sticky bar ---- */
.cp-stickybar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(15,15,15,0.95);
  backdrop-filter: blur(10px);
  border-top: 1px solid #2a2a2a;
  padding: 12px 20px;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.cp-stickybar__price { color: var(--cr-red, #e53935); font-weight: 800; font-size: 1.2rem; }
.cp-stickybar__reg { color: var(--cr-muted, #999); text-decoration: line-through; font-size: 0.78rem; }

/* ---- Lightbox ---- */
.cp-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,0.92);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.cp-lightbox.open { display: flex; }
.cp-lightbox img { max-width: 90vw; max-height: 85vh; object-fit: contain; border-radius: 8px; }
.cp-lightbox__close {
  position: absolute;
  top: 20px;
  right: 28px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.5rem;
  cursor: pointer;
  line-height: 1;
  transition: transform 0.2s ease;
}
.cp-lightbox__close:hover { transform: rotate(90deg); }

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .cp-top { grid-template-columns: 1fr; gap: 28px; }
  .cp-related__grid { grid-template-columns: repeat(2, 1fr); }
  .cp-stickybar { display: flex; }
  .chanren-product { padding-bottom: 90px; }
}

@media (max-width: 480px) {
  .cp-trust { grid-template-columns: 1fr; }
  .cp-buybox__title { font-size: 1.3rem; }
  .cp-buybox__sale { font-size: 1.5rem; }
}
