/* ============================================================
   RQ MEDICAL — product.css
   Estilos específicos de la página de detalle de producto y 404.
   Depende de las variables y componentes definidos en main.css.
   ============================================================ */

/* === 1. BOTÓN GRANDE (variante local, no está en main.css) === */
.btn-lg {
  padding: 18px 38px;
  font-size: 1.02rem;
}

/* === 2. HERO DE PRODUCTO === */
.product-hero {
  position: relative;
  padding: 160px 0 80px;
  background: linear-gradient(180deg, var(--mist) 0%, var(--white) 100%);
  overflow: hidden;
}

.product-hero-dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--steel) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.08;
  pointer-events: none;
}

/* === 2.1 Breadcrumb === */
.breadcrumb {
  position: relative;
  margin-bottom: 40px;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--steel);
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb li:not(:last-child)::after {
  content: '/';
  color: var(--steel);
  opacity: 0.5;
}

.breadcrumb a {
  color: var(--teal);
  font-weight: 600;
  transition: color 0.25s ease;
}

.breadcrumb a:hover {
  color: var(--aqua);
}

.breadcrumb li[aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
}

/* === 2.2 Grid principal del hero === */
.product-hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 64px;
  align-items: start;
}

/* === 2.3 Galería === */
.product-gallery {
  position: sticky;
  top: 110px;
}

.gallery-main {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.gallery-main img,
.gallery-main video {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Variante con video: sin relleno y fondo oscuro, para que las bandas del
   video (si su proporción no es cuadrada) no se vean como un marco blanco */
.gallery-main--video {
  padding: 0;
  background: var(--ink);
}

.gallery-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.thumb {
  width: 76px;
  height: 76px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--white);
  border: 2px solid var(--mist-strong);
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.thumb:hover {
  transform: translateY(-2px);
  border-color: var(--steel);
}

.thumb.is-active {
  border-color: var(--aqua);
  box-shadow: 0 0 0 3px rgba(88, 174, 181, 0.16);
}

/* === 2.4 Información de producto === */
.product-info {
  padding-top: 6px;
}

.product-info .badge-tag {
  margin-bottom: 18px;
}

.product-info h1 {
  margin-bottom: 20px;
}

.product-description {
  font-size: 1.08rem;
  line-height: 1.75;
  color: var(--steel);
  margin-bottom: 32px;
}

.product-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 32px;
}

/* === 2.5 Callout destacado (highlight) === */
.product-highlight {
  background: linear-gradient(135deg, var(--mist), var(--mist-strong));
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 32px;
}

.product-highlight-title {
  display: block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  color: var(--teal);
  margin-bottom: 8px;
}

.product-highlight p {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--ink);
}

/* === 2.6 Bloque "Incluye" === */
.includes-box {
  margin-bottom: 32px;
}

.includes-title {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 12px;
}

.includes-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.includes-list li {
  position: relative;
  padding-left: 26px;
  font-size: 0.95rem;
  color: var(--steel);
  line-height: 1.5;
}

.includes-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.4em;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--mist);
  box-shadow: inset 0 0 0 2px var(--aqua);
}

.includes-list li::after {
  content: '';
  position: absolute;
  left: 4px;
  top: 0.55em;
  width: 6px;
  height: 3px;
  border-left: 2px solid var(--teal);
  border-bottom: 2px solid var(--teal);
  transform: rotate(-45deg);
}

/* === 2.7 Caja de asistencia técnica === */
.assistance-box {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--mist);
  border-radius: var(--radius);
  padding: 22px 24px;
}

.assistance-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--white);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.assistance-icon svg {
  width: 22px;
  height: 22px;
}

.assistance-title {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 6px;
}

.assistance-text p {
  font-size: 0.92rem;
  color: var(--steel);
  line-height: 1.6;
}

/* === 3. CARACTERÍSTICAS === */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.feature-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s var(--ease-smooth), box-shadow 0.4s var(--ease-smooth);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
}

.feature-icon svg {
  width: 100%;
  height: 100%;
}

.feature-card p {
  font-size: 0.98rem;
  color: var(--ink);
  font-weight: 500;
  line-height: 1.5;
}

/* === 4. TABLA DE ESPECIFICACIONES === */
.specs-table-wrap {
  overflow-x: auto;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 8px 24px;
}

/* === 5. DETALLE TÉCNICO === */
.detail-group + .detail-group {
  margin-top: 40px;
}

.detail-group-title {
  font-size: 1.15rem;
  margin-bottom: 20px;
}

.detail-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.detail-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s var(--ease-smooth), box-shadow 0.4s var(--ease-smooth);
}

.detail-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.detail-card-label {
  display: block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--teal);
  margin-bottom: 8px;
}

.detail-card p {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--steel);
}

/* === 6. BENEFICIOS Y ALCANCES (LISTAS) === */
.list-block + .list-block {
  margin-top: 36px;
}

.list-block-title {
  font-size: 1.1rem;
  margin-bottom: 18px;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  background: var(--white);
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.4;
  padding: 10px 16px 10px 34px;
  border-radius: 100px;
  box-shadow: var(--shadow-sm);
}

.chip::before {
  content: '';
  position: absolute;
  left: 14px;
  top: 50%;
  width: 5px;
  height: 9px;
  border-right: 2px solid var(--aqua);
  border-bottom: 2px solid var(--aqua);
  transform: translateY(-65%) rotate(45deg);
}

/* === 7. DOCUMENTACIÓN === */
.docs-section .section-head {
  margin-bottom: 40px;
}

.docs-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.doc-card {
  display: flex;
  align-items: center;
  gap: 18px;
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease-smooth), box-shadow 0.35s var(--ease-smooth);
}

.doc-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.doc-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--mist);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
}

.doc-icon svg {
  width: 22px;
  height: 22px;
}

.doc-label {
  flex: 1;
  font-weight: 600;
  color: var(--ink);
}

/* === 8. CTA DE CONVERSIÓN === */
.product-cta {
  position: relative;
  padding: 80px 0;
  overflow: hidden;
}

.product-cta-dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--aqua) 1px, transparent 1px);
  background-size: 30px 30px;
  opacity: 0.12;
  pointer-events: none;
}

.product-cta-dots::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 480px;
  height: 480px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(88, 174, 181, 0.25), transparent 70%);
  filter: blur(20px);
}

.product-cta-inner {
  position: relative;
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
}

.product-cta-inner h2 {
  margin-bottom: 14px;
}

.product-cta-inner p {
  margin-bottom: 32px;
  font-size: 1.05rem;
}

/* === 9. RELACIONADOS === */
#related .card-desc {
  -webkit-line-clamp: 3;
}

/* === 10. PÁGINA 404 === */
.not-found-section {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  padding: 160px 0 60px;
  overflow: hidden;
  background: linear-gradient(180deg, var(--mist) 0%, var(--white) 100%);
}

.not-found-dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--steel) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.08;
  pointer-events: none;
}

.not-found-inner {
  position: relative;
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
}

.not-found-code {
  display: block;
  font-family: var(--font-heading);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(5rem, 16vw, 9rem);
  line-height: 1;
  margin-bottom: 12px;
}

.not-found-inner h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 16px;
}

.not-found-inner p {
  color: var(--steel);
  font-size: 1.02rem;
  line-height: 1.7;
  margin-bottom: 32px;
}

.not-found-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.not-found-suggestions .product-card-compact .card-media {
  aspect-ratio: 4 / 3;
}

/* === 11. RESPONSIVE === */
@media (max-width: 1200px) {
  .product-hero-grid {
    gap: 48px;
  }
}

@media (max-width: 992px) {
  .product-hero {
    padding: 130px 0 60px;
  }

  .product-hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .product-gallery {
    position: static;
    max-width: 480px;
    margin: 0 auto;
  }

  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .product-hero {
    padding: 120px 0 50px;
  }

  .gallery-main {
    padding: 14px;
  }

  .product-cta-group {
    flex-direction: column;
  }

  .product-cta-group .btn {
    width: 100%;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .detail-cards-grid {
    grid-template-columns: 1fr;
  }

  .chip {
    font-size: 0.85rem;
    padding: 9px 14px 9px 30px;
  }

  .doc-card {
    flex-wrap: wrap;
  }

  .doc-card .btn {
    width: 100%;
    justify-content: center;
  }

  .specs-table-wrap {
    padding: 8px 14px;
  }
}

@media (max-width: 480px) {
  .thumb {
    width: 62px;
    height: 62px;
  }

  .not-found-code {
    font-size: clamp(4rem, 22vw, 6rem);
  }

  .not-found-actions {
    flex-direction: column;
    width: 100%;
  }

  .not-found-actions .btn {
    width: 100%;
  }
}
