/* ============================================================================
 * ketodietfat Boutique Affiliate E-Commerce Stylesheet (WooCommerce)
 * Palette: W4 Soft Ivory Linen (#fdfbf7) + Tinted Sand (#f4efe6) + Pure White
 * Accents: Ember Orange (#ea580c) + Crisp Teal (#0d9488) + Espresso Ink (#292524)
 * ============================================================================ */

/* --- SHOP ARCHIVE & PRODUCT GRID --- */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.75rem;
}

.woocommerce ul.products::before,
.woocommerce ul.products::after {
  display: none !important;
}

.woocommerce ul.products li.product {
  width: 100% !important;
  margin: 0 !important;
  background: #ffffff;
  border: 1.5px solid #e7e0d4;
  border-radius: 16px;
  padding: 1.35rem !important;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.woocommerce ul.products li.product:hover {
  transform: translateY(-3px);
  border-color: #0d9488;
  box-shadow: 0 14px 32px -12px rgba(41, 37, 36, 0.12);
}

.woocommerce ul.products li.product img {
  background: #fdfbf7;
  border-radius: 12px;
  padding: 0.75rem;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  margin-bottom: 1rem !important;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: "Instrument Serif", Georgia, serif;
  font-size: 1.45rem !important;
  line-height: 1.2 !important;
  color: #292524;
  padding: 0.25rem 0 0.5rem !important;
}

.woocommerce ul.products li.product .price {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.9rem;
  color: #0d9488 !important;
  font-weight: 600;
  margin-bottom: 0.85rem;
}

/* --- PRIMARY AFFILIATE CTA BUTTONS (EMBER ORANGE) --- */
.woocommerce a.button,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.kdf-affiliate-cta {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  background-color: #ea580c !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 10px !important;
  padding: 0.9rem 1.35rem !important;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.85rem !important;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: background-color 0.18s ease, transform 0.15s ease;
}

.woocommerce a.button:hover,
.woocommerce button.button.alt:hover,
.kdf-affiliate-cta:hover {
  background-color: #9a3412 !important;
  transform: translateY(-1px);
}

/* --- SINGLE PRODUCT PAGE (BOUTIQUE SPLIT HERO) --- */
.woocommerce div.product {
  max-width: 1120px;
  margin: 2rem auto 4rem;
}

.woocommerce div.product div.images {
  background: #ffffff;
  border: 1.5px solid #e7e0d4;
  border-radius: 18px;
  padding: 1.5rem;
}

.woocommerce div.product .product_title {
  font-family: "Instrument Serif", Georgia, serif;
  font-size: clamp(2rem, 3.2vw, 2.85rem);
  line-height: 1.12;
  color: #292524;
  margin-bottom: 0.75rem;
}

.woocommerce div.product .woocommerce-product-details__short-description {
  color: #57534e;
  font-size: 1.02rem;
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.kdf-affiliate-buybox {
  margin: 1.25rem 0 1.5rem;
  padding: 1.25rem;
  background: #f4efe6;
  border: 1px solid #e7e0d4;
  border-radius: 14px;
}

.kdf-affiliate-disclosure {
  margin: 0.75rem 0 0 !important;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.74rem;
  line-height: 1.5;
  color: #57534e;
}

.woocommerce span.onsale {
  background-color: #0d9488 !important;
  color: #ffffff !important;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  border-radius: 999px;
}

.woocommerce-message,
.woocommerce-info {
  border-top-color: #0d9488 !important;
  background-color: #f4efe6 !important;
  color: #292524;
  border-radius: 10px;
}

/* --- EDITORIAL PRODUCT PATTERN COMPONENTS (Spec Bar + Pros/Cons) --- */
.kdf-prod-editorial {
  margin: 2rem 0;
  color: #292524;
}

.kdf-prod-specs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  background: #f4efe6;
  border: 1px solid #e7e0d4;
  border-radius: 14px;
  padding: 1.25rem;
  margin-bottom: 2rem;
}

.kdf-spec-item {
  background: #ffffff;
  border: 1px solid #e7e0d4;
  border-radius: 10px;
  padding: 0.95rem 1rem;
}

.kdf-spec-label {
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #57534e;
  margin-bottom: 0.35rem;
}

.kdf-spec-val {
  display: block;
  font-family: "Instrument Serif", Georgia, serif;
  font-size: 1.4rem;
  color: #292524;
  line-height: 1.15;
}

.kdf-spec-sub {
  display: block;
  font-size: 0.78rem;
  color: #0d9488;
  margin-top: 0.25rem;
  font-weight: 600;
}

.kdf-prod-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin: 1.75rem 0;
}

.kdf-prod-box {
  background: #ffffff;
  border: 1.5px solid #e7e0d4;
  border-radius: 14px;
  padding: 1.4rem 1.5rem;
}

.kdf-prod-box-teal {
  border-top: 4px solid #0d9488;
}

.kdf-prod-box-stone {
  border-top: 4px solid #ea580c;
}

.kdf-prod-box h4 {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.8rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  margin: 0 0 0.85rem;
}

.kdf-prod-box-teal h4 { color: #0d9488; }
.kdf-prod-box-stone h4 { color: #ea580c; }

.kdf-prod-box ul {
  margin: 0;
  padding-left: 1.15rem;
  color: #57534e;
  line-height: 1.65;
}

@media (max-width: 900px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kdf-prod-specs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kdf-prod-split {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .woocommerce ul.products {
    grid-template-columns: 1fr;
  }
}
