/* ================================================================
   product-detail.css — Product Detail Page (PDP)
   Dark theme consistente con el resto del sitio
   ================================================================ */

/* ── Breadcrumb ─────────────────────────────────────────────── */
.pdp-breadcrumb {
  padding: 1.2rem 0 0.4rem;
  font-size: 0.82rem;
  color: #888;
}
.pdp-breadcrumb a {
  color: #aaa;
  text-decoration: none;
  transition: color 0.2s;
}
.pdp-breadcrumb a:hover { color: #00c8d4; }
.pdp-breadcrumb i {
  margin: 0 0.35rem;
  font-size: 0.7rem;
  vertical-align: middle;
  opacity: 0.6;
}
.pdp-breadcrumb span {
  color: #e0e0e0;
  font-weight: 500;
  /* clamp title length */
  display: inline-block;
  max-width: 320px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: bottom;
}

/* ── Main layout ────────────────────────────────────────────── */
.pdp-main-block {
  padding: 1.5rem 0 3rem;
}
.pdp-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
@media (max-width: 860px) {
  .pdp-layout { grid-template-columns: 1fr; gap: 1.5rem; }
}

/* ── Gallery ────────────────────────────────────────────────── */
.pdp-gallery {
  position: sticky;
  top: 90px;
}
.pdp-img-main {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.pdp-img-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 1.5rem;
  transition: transform 0.4s ease;
}
.pdp-img-main:hover img { transform: scale(1.04); }

/* ── Info panel ─────────────────────────────────────────────── */
.pdp-info { display: flex; flex-direction: column; gap: 1.1rem; }

/* Badges */
.pdp-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.pdp-badge {
  padding: 0.3rem 0.75rem;
  border-radius: 50px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.pdp-badge--oferta  { background: linear-gradient(135deg,#FF4444,#CC0000); color:#fff; }
.pdp-badge--preorder{ background: linear-gradient(135deg,#7B00FF,#5500CC); color:#fff; }
.pdp-badge--new     { background: linear-gradient(135deg,#00C8D4,#007A80); color:#fff; }
.pdp-badge--hot     { background: linear-gradient(135deg,#FF8C00,#CC5500); color:#fff; }

/* Title */
.pdp-title {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  margin: 0;
}

/* Price block */
.pdp-price-block {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.pdp-compare-price {
  font-size: 1rem;
  color: #888;
  text-decoration: line-through;
}
.pdp-main-price {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: #00c8d4;
}
.pdp-savings {
  font-size: 0.85rem;
  font-weight: 700;
  color: #ff4444;
  background: rgba(255,68,68,0.12);
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
}

/* Stock status */
.pdp-stock {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
}
.pdp-stock-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.pdp-stock--in  { color: #4ade80; }
.pdp-stock--in  .pdp-stock-dot { background: #4ade80; box-shadow: 0 0 6px #4ade80; }
.pdp-stock--out { color: #f87171; }
.pdp-stock--out .pdp-stock-dot { background: #f87171; }

/* Variant selector */
.pdp-variants {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.pdp-variants-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.pdp-variant-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.pdp-variant-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  padding: 0.55rem 1.1rem;
  border: 2px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.04);
  border-radius: 10px;
  color: #e0e0e0;
  font-family: 'Outfit', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  line-height: 1.2;
}
.pdp-variant-btn:hover {
  border-color: #00c8d4;
  background: rgba(0,200,212,0.08);
  color: #fff;
}
.pdp-variant-btn.active {
  border-color: #00c8d4;
  background: rgba(0,200,212,0.15);
  color: #fff;
}
.pdp-vbtn-lang {
  font-size: 0.88rem;
  font-weight: 600;
}
.pdp-variant-price {
  font-size: 0.82rem;
  font-weight: 700;
  color: #00c8d4;
}
.pdp-variant-btn.active .pdp-variant-price { color: #00f0ff; }
.pdp-vbtn-compare {
  font-size: 0.72rem;
  color: #666;
  text-decoration: line-through;
}

/* Botón agotado */
.pdp-vbtn--out {
  opacity: 0.55;
  border-color: rgba(248,113,113,0.3) !important;
  cursor: not-allowed;
}
.pdp-vbtn--out .pdp-variant-price { color: #f87171; }

/* Botón preventa */
.pdp-vbtn--pre {
  border-color: rgba(139,92,246,0.4);
}
.pdp-vbtn--pre .pdp-variant-price { color: #a78bfa; }
.pdp-vbtn--pre.active { border-color: #8b5cf6; background: rgba(139,92,246,0.15); }

/* Estado label dentro del botón */
.pdp-vbtn-state {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  line-height: 1.4;
}
.pdp-vbtn-state--out { background: rgba(248,113,113,0.15); color: #f87171; }
.pdp-vbtn-state--pre { background: rgba(139,92,246,0.15); color: #a78bfa; }

/* ── Strip de preventa ──────────────────────────────────────── */
.pdp-preorder-strip {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1.2rem;
  background: linear-gradient(135deg, rgba(139,92,246,0.15), rgba(109,40,217,0.1));
  border: 1px solid rgba(139,92,246,0.35);
  border-radius: 12px;
  animation: pdpStripPulse 3s ease-in-out infinite;
}
@keyframes pdpStripPulse {
  0%, 100% { border-color: rgba(139,92,246,0.35); }
  50%       { border-color: rgba(139,92,246,0.65); }
}
.pdp-preorder-strip-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  line-height: 1;
  margin-top: 2px;
}
.pdp-preorder-strip-text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  font-size: 0.88rem;
  line-height: 1.4;
  color: #c4b5fd;
}
.pdp-preorder-strip-text strong { color: #ede9fe; font-size: 0.92rem; }
.pdp-preorder-strip-text span { color: #a78bfa; font-size: 0.8rem; }

/* Cart row */
.pdp-cart-row {
  display: flex;
  gap: 0.75rem;
  align-items: stretch;
  flex-wrap: wrap;
}
.pdp-qty {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255,255,255,0.04);
}
.pdp-qty-btn {
  width: 40px;
  height: 46px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  transition: background 0.15s;
  flex-shrink: 0;
}
.pdp-qty-btn:hover { background: rgba(255,255,255,0.08); }
#pdp-qty-input {
  width: 48px;
  height: 46px;
  background: transparent;
  border: none;
  border-left: 1px solid rgba(255,255,255,0.1);
  border-right: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  text-align: center;
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  -moz-appearance: textfield;
}
#pdp-qty-input::-webkit-inner-spin-button,
#pdp-qty-input::-webkit-outer-spin-button { -webkit-appearance: none; }

.pdp-btn-cart {
  flex: 1;
  min-width: 180px;
  padding: 0 1.5rem;
  height: 48px;
  background: linear-gradient(135deg, #00c8d4, #007a80);
  border: none;
  border-radius: 10px;
  color: #000;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s;
  letter-spacing: 0.02em;
}
.pdp-btn-cart:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,200,212,0.4);
}
.pdp-btn-cart:active { transform: translateY(0); }

.pdp-btn-preorder {
  width: 100%;
  background: linear-gradient(135deg, #7B00FF, #5500CC);
  color: #fff;
}
.pdp-btn-preorder:hover {
  box-shadow: 0 6px 20px rgba(123,0,255,0.4);
}

.pdp-out-of-stock-msg {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.2rem;
  background: rgba(248,113,113,0.1);
  border: 1px solid rgba(248,113,113,0.2);
  border-radius: 10px;
  color: #f87171;
  font-weight: 600;
  font-size: 0.9rem;
}

/* Shipping info */
.pdp-shipping-block {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding: 1rem 1.2rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
}
.pdp-shipping-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}
.pdp-shipping-row i {
  font-size: 1.2rem;
  color: #00c8d4;
  flex-shrink: 0;
  margin-top: 2px;
}
.pdp-shipping-row div {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.pdp-shipping-row strong {
  font-size: 0.88rem;
  font-weight: 700;
  color: #e0e0e0;
}
.pdp-shipping-row span {
  font-size: 0.8rem;
  color: #888;
}

/* Description panel */
.pdp-desc-panel {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  overflow: hidden;
}
.pdp-desc-panel summary {
  padding: 0.9rem 1.2rem;
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: #e0e0e0;
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  background: rgba(255,255,255,0.03);
  transition: background 0.15s;
}
.pdp-desc-panel summary:hover { background: rgba(255,255,255,0.06); }
.pdp-desc-panel summary::after {
  content: '+';
  font-size: 1.2rem;
  color: #00c8d4;
  font-weight: 300;
  transition: transform 0.2s;
}
.pdp-desc-panel[open] summary::after { content: '−'; }
.pdp-desc-body {
  padding: 1rem 1.2rem 1.2rem;
  font-size: 0.88rem;
  color: #aaa;
  line-height: 1.6;
}
.pdp-desc-body p { margin: 0; }

/* ── Recommended products section ───────────────────────────── */
.pdp-rec-section {
  padding: 3rem 0 4rem;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.pdp-rec-grid {
  margin-top: 1.5rem;
}

/* ── Not found ──────────────────────────────────────────────── */
.pdp-not-found {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 6rem 2rem;
  text-align: center;
  color: #888;
}
.pdp-not-found h2 { color: #e0e0e0; }
