/* ==========================================================================
   product.css — Individual Product Page Styles
   Used on: pages/products/*.html (loaded after blog.css, which provides the
   page background, article card, body typography and CTA box)
   ========================================================================== */


/* --------------------------------------------------------------------------
   BREADCRUMB
   -------------------------------------------------------------------------- */
.product-breadcrumb {
  font-size: var(--text-sm);
  color: var(--color-text-mid);
  margin-bottom: var(--space-6);
}

.product-breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.product-breadcrumb li + li::before {
  content: '›';
  margin-right: var(--space-2);
  color: var(--color-text-mid);
}

.product-breadcrumb a {
  color: var(--color-green-dark);
  font-weight: var(--weight-medium);
}

.product-breadcrumb a:hover {
  text-decoration: underline;
}


/* --------------------------------------------------------------------------
   HERO — image + key facts
   -------------------------------------------------------------------------- */
.product-hero {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: var(--space-8);
  align-items: center;
  margin-bottom: var(--space-8);
}

.product-hero__image {
  background-color: var(--color-off-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
}

.product-hero__image img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.product-hero__lead {
  font-size: var(--text-md);
  line-height: var(--line-normal);
  color: var(--color-text-mid);
  margin-top: var(--space-3);
}

.product-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}


/* --------------------------------------------------------------------------
   SPECIFICATIONS TABLE
   -------------------------------------------------------------------------- */
.product-specs {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
}

.product-specs th,
.product-specs td {
  text-align: left;
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}

.product-specs th {
  width: 40%;
  font-weight: var(--weight-semibold);
  color: var(--color-text-dark);
  background-color: var(--color-green-pale);
}


/* --------------------------------------------------------------------------
   VARIANT GALLERY (PP woven bags, kraft paper bags)
   -------------------------------------------------------------------------- */
.product-variants {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: var(--space-4);
}

.product-variants figure {
  background-color: var(--color-off-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  text-align: center;
}

.product-variants img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
}

.product-variants figcaption {
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--color-text-dark);
  line-height: var(--line-snug);
}


/* --------------------------------------------------------------------------
   RELATED PRODUCTS
   -------------------------------------------------------------------------- */
.product-related {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: var(--space-4);
  padding-left: 0 !important;
  list-style: none !important;
}

.product-related a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  height: 100%;
  padding: var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  text-decoration: none !important;
  color: var(--color-text-dark) !important;
  font-size: var(--text-sm);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.product-related a:hover {
  border-color: var(--color-green-mid);
  box-shadow: var(--shadow-md);
}

.product-related img {
  width: 96px;
  height: 96px;
  object-fit: contain;
}


/* --------------------------------------------------------------------------
   RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 700px) {
  .product-hero {
    grid-template-columns: 1fr;
  }

  .product-hero__image {
    max-width: 280px;
    margin-inline: auto;
  }

  .product-specs th {
    width: 45%;
  }
}
