/*
 * products.css — Western Trade Products Overview + Detail Pages
 * Domain: ewesterntrade.com | Updated: 2026-10-16
 */

/* Products overview grid — large cards */
.products-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  margin-top: var(--space-10);
}
@media (min-width: 768px) {
  .products-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  /* 2-2-1 layout: first two full, then 2, then 1 centered */
  .products-grid { grid-template-columns: repeat(2, 1fr); }
}

.product-overview-card {
  background: var(--color-white);
  border-radius: var(--border-radius-xl);
  overflow: hidden;
  border: 1px solid var(--color-border);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.product-overview-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-4px);
}

.product-overview-card__img-wrap {
  position: relative;
  height: 240px;
  overflow: hidden;
}

.product-overview-card__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-overview-card:hover .product-overview-card__img-wrap img {
  transform: scale(1.05);
}

.product-overview-card__body {
  padding: var(--space-8);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-overview-card__partner {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-3);
}

.product-overview-card h3 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-4);
}

.product-overview-card p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  flex: 1;
  margin-bottom: var(--space-6);
}

.product-overview-card__features {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
}

.product-overview-card__features li {
  font-size: var(--text-xs);
  font-weight: 600;
  padding: var(--space-1) var(--space-3);
  background: rgba(11, 61, 145, 0.07);
  color: var(--color-primary);
  border-radius: var(--border-radius-full);
}

/* ---- PRODUCT DETAIL PAGE styles ---- */

.product-detail-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
  align-items: start;
}
@media (min-width: 1024px) {
  .product-detail-split { grid-template-columns: 1fr 1fr; }
}

.product-detail-img {
  border-radius: var(--border-radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  aspect-ratio: 4/3;
}

.product-detail-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail-info__partner {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  background: rgba(212, 175, 55, 0.10);
  border: 1px solid rgba(212, 175, 55, 0.30);
  border-radius: var(--border-radius-full);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-5);
}

/* h2 (not h1) — the page hero already holds the single h1 */
.product-detail-info h1,
.product-detail-info h2 {
  font-size: var(--text-4xl);
  font-weight: 800;
  margin-bottom: var(--space-5);
}

.product-detail-info p {
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-6);
}

/* Feature tags */
.product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-8);
}

.product-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-2) var(--space-4);
  background: rgba(11, 61, 145, 0.07);
  color: var(--color-primary);
  border-radius: var(--border-radius-full);
  font-size: var(--text-sm);
  font-weight: 600;
}

.product-tag::before {
  content: '✓';
  color: var(--color-accent);
}

/* Specs table */
.product-specs {
  margin-top: var(--space-12);
}

.product-specs h2 {
  margin-bottom: var(--space-6);
}

.specs-table {
  width: 100%;
  border-collapse: collapse;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.specs-table tr:nth-child(odd) td:first-child,
.specs-table th {
  background: var(--color-primary);
  color: var(--color-white);
}

.specs-table th {
  padding: var(--space-4) var(--space-6);
  text-align: left;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.specs-table td {
  padding: var(--space-4) var(--space-6);
  font-size: var(--text-sm);
  border-bottom: 1px solid var(--color-border);
}

.specs-table tr:nth-child(even) {
  background: var(--color-bg);
}

.specs-table tr:nth-child(odd) {
  background: var(--color-white);
}

.specs-table td:first-child {
  font-weight: 600;
  color: var(--color-primary);
  width: 40%;
}

/* Related products */
.related-products {
  margin-top: var(--space-16);
}

.related-products h2 {
  margin-bottom: var(--space-8);
}

.related-grid {
  display: grid;
  /* Mobile: 1 column — cards are tall, 3-up is too cramped on phones.
     Tablet 640px+: 2 columns.
     Desktop 768px+: 3 columns. */
  grid-template-columns: 1fr;
  gap: var(--space-4);
}
@media (min-width: 640px) {
  .related-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 768px) {
  .related-grid { grid-template-columns: repeat(3, 1fr); }
}
