/*
 * Healing Thyme – WooCommerce Custom Templates CSS
 * Enqueue via functions.php  →  wp_enqueue_style('ht-woo', ...)
 *
 * Palette
 * --ht-cream  : #F5F0E8  (hero / section bg)
 * --ht-warm   : #E8DDD0  (card bg)
 * --ht-sand   : #C8B89A  (borders, dividers)
 * --ht-forest : #2C3E2D  (CTA, dark text)
 * --ht-bark   : #5C4A32  (headings)
 * --ht-moss   : #6B7C5E  (accents)
 * --ht-ink    : #1A1A1A  (body text)
 */

/* ─── TOKENS ──────────────────────────────────────────────────────────────── */
:root {
  --ht-cream  : #F5F0E8;
  --ht-warm   : #EEEAE2;
  --ht-sand   : #C8B89A;
  --ht-forest : #2C3E2D;
  --ht-bark   : #5C4A32;
  --ht-moss   : #6B7C5E;
  --ht-ink    : #1A1A1A;
  --ht-white  : #FFFFFF;

  --ht-r     : 6px;
  --ht-r-lg  : 14px;
  --ht-r-xl  : 24px;

  --ht-shadow : 0 2px 12px rgba(44,62,45,.08);
  --ht-shadow-hover : 0 8px 32px rgba(44,62,45,.16);

  --ht-font-display : 'Playfair Display', Georgia, serif;
  --ht-font-body    : 'Inter', 'Helvetica Neue', sans-serif;

  --ht-max-w : 1300px;
  --ht-gap   : clamp(16px, 3vw, 32px);
}

/* ─── RESET SCOPE ─────────────────────────────────────────────────────────── */
.ht-shop-wrap *,
.ht-single-wrap * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SHOP PAGE
═══════════════════════════════════════════════════════════════════════════ */

/* ── Hero ─────────────────────────────────────────────────────────────────── */
.ht-shop-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 320px;
  background: var(--ht-cream);
  overflow: hidden;
}

.ht-shop-hero__content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(40px,8vw,100px) clamp(28px,5vw,72px);
}

.ht-shop-hero__eyebrow {
  font-family: var(--ht-font-body);
  font-size: 11px !important;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ht-moss);
  margin-bottom: 12px;
}

.ht-shop-hero__heading {
  font-family: var(--ht-font-display);
  font-size: clamp(52px, 8vw, 96px) !important;
  font-weight: 700;
  color: var(--ht-bark);
  line-height: 1;
  margin-bottom: 20px;
}

.ht-shop-hero__sub {
  font-family: var(--ht-font-body);
  font-size: clamp(14px, 1.6vw, 18px) !important;
  color: var(--ht-ink);
  line-height: 1.65;
  opacity: .75;
}

.ht-shop-hero__img-wrap {
  overflow: hidden;
}

.ht-shop-hero__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* ── Filter Bar ───────────────────────────────────────────────────────────── */
.ht-shop-filter {
  background: var(--ht-white);
  border-bottom: 1px solid var(--ht-sand);
  position: sticky;
  top: 0;
  z-index: 40;
}

.ht-shop-filter__inner {
  max-width: var(--ht-max-w);
  margin: 0 auto;
  padding: 14px var(--ht-gap);
}

.ht-shop-filter__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ht-cat-pill {
  font-family: var(--ht-font-body);
  font-size: 13px !important;
  font-weight: 500;
  padding: 6px 18px;
  border-radius: 999px;
  border: 1.5px solid var(--ht-sand);
  color: var(--ht-ink);
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s;
  white-space: nowrap;
}

.ht-cat-pill:hover,
.ht-cat-pill.is-active {
  background: var(--ht-forest);
  border-color: var(--ht-forest);
  color: var(--ht-white);
}

/* ── Product Grid ─────────────────────────────────────────────────────────── */
.ht-shop-grid-section {
  background: var(--ht-white);
  padding: clamp(40px, 6vw, 80px) var(--ht-gap);
}

.ht-shop-grid {
  max-width: var(--ht-max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

/* ── Product Card ─────────────────────────────────────────────────────────── */
.ht-product-card {
  display: block;
  text-decoration: none;
  border-radius: var(--ht-r-lg);
  overflow: hidden;
  background: var(--ht-warm);
  border: 1px solid transparent;
  transition: box-shadow .22s, border-color .22s, transform .22s;
}

.ht-product-card:hover {
  box-shadow: var(--ht-shadow-hover);
  border-color: var(--ht-sand);
  transform: translateY(-3px);
}

.ht-product-card__img-wrap {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--ht-cream);
}

.ht-product-card__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
  display: block;
}

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

.ht-product-card__body {
  padding: 16px 18px 20px;
}

.ht-product-card__name {
  font-family: var(--ht-font-display);
  font-size: 16px !important;
  font-weight: 600;
  color: var(--ht-bark);
  line-height: 1.3;
}

/* ── No Products ──────────────────────────────────────────────────────────── */
.ht-no-products {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--ht-moss);
  font-family: var(--ht-font-body);
  padding: 60px 0;
}

/* ── Pagination ───────────────────────────────────────────────────────────── */
.ht-shop-pagination {
  max-width: var(--ht-max-w);
  margin: 40px auto 0;
  text-align: center;
}

.ht-btn-outline {
  font-family: var(--ht-font-body);
  font-size: 14px !important;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 14px 40px;
  border-radius: var(--ht-r);
  border: 2px solid var(--ht-forest);
  color: var(--ht-forest);
  background: transparent;
  cursor: pointer;
  transition: background .18s, color .18s;
}

.ht-btn-outline:hover {
  background: var(--ht-forest);
  color: var(--ht-white);
}


/* ═══════════════════════════════════════════════════════════════════════════
   SINGLE PRODUCT PAGE
═══════════════════════════════════════════════════════════════════════════ */

.ht-single-wrap {
  font-family: var(--ht-font-body);
  color: var(--ht-ink);
}

/* ── Section 1: Gallery + Info ────────────────────────────────────────────── */
.ht-pdp-top {
  background: var(--ht-cream);
  padding: clamp(32px,5vw,72px) var(--ht-gap);
}

.ht-pdp-top__inner {
  max-width: var(--ht-max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

/* Gallery */
.ht-pdp-gallery__main {
  border-radius: var(--ht-r-xl);
  overflow: hidden;
  background: var(--ht-white);
  aspect-ratio: 1 / 1;
}

.ht-pdp-gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity .2s;
}

.ht-pdp-gallery__thumbs {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
}

.ht-pdp-gallery__thumbs::-webkit-scrollbar {
  height: 4px;
}

.ht-pdp-gallery__thumbs::-webkit-scrollbar-track {
  background: transparent;
}

.ht-pdp-gallery__thumbs::-webkit-scrollbar-thumb {
  background: var(--ht-sand);
  border-radius: 2px;
}

.ht-thumb {
  width: 72px;
  height: 72px;
  border-radius: var(--ht-r);
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  background: none;
  transition: border-color .18s;
  flex-shrink: 0;
}

.ht-thumb.is-active,
.ht-thumb:hover {
  border-color: var(--ht-forest);
}

.ht-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Product Info */
.ht-pdp-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.ht-pdp-meta__cat {
  font-size: 11px !important;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--ht-moss);
}

.ht-tag {
  font-size: 11px !important;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--ht-sand);
  color: var(--ht-bark);
  font-weight: 500;
}

.ht-pdp-title {
  font-family: var(--ht-font-display);
  font-size: clamp(28px, 3.5vw, 44px) !important;
  font-weight: 700;
  color: var(--ht-bark);
  line-height: 1.15;
  margin-bottom: 16px;
}

.ht-pdp-price {
  font-size: clamp(20px, 2vw, 26px) !important;
  font-weight: 700;
  color: var(--ht-ink);
  margin-bottom: 20px;
}

.ht-pdp-price .woocommerce-Price-amount { color: var(--ht-ink); }
.ht-pdp-price del { color: var(--ht-sand); font-weight: 400; }
.ht-pdp-price ins { text-decoration: none; }

.ht-pdp-short-desc {
  font-size: 15px !important;
  line-height: 1.7;
  color: var(--ht-ink);
  opacity: .8;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--ht-sand);
}

/* USPs */
.ht-pdp-usps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 28px;
}

.ht-pdp-usp {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ht-pdp-usp__icon {
  font-size: 18px !important;
  width: 28px;
  text-align: center;
  flex-shrink: 0;
}

.ht-pdp-usp__text {
  font-size: 14px !important;
  font-weight: 500;
  color: var(--ht-ink);
}

/* Enquire Button */
.ht-btn-enquire {
  display: block;
  width: 100%;
  padding: 16px 24px;
  background: var(--ht-forest);
  color: var(--ht-white);
  font-family: var(--ht-font-body);
  font-size: 15px !important;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  border: none;
  border-radius: var(--ht-r);
  cursor: pointer;
  transition: background .18s, transform .14s;
  margin-bottom: 16px;
  text-align: center;
}

.ht-btn-enquire:hover {
  background: #1a2e1b;
  transform: translateY(-1px);
}

.ht-pdp-bulk-note {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px !important;
  color: var(--ht-moss);
  font-weight: 500;
}

.ht-pdp-bulk-note svg { flex-shrink: 0; }

/* ── Section 2: Icon Boxes ────────────────────────────────────────────────── */
.ht-pdp-icons {
  background: var(--ht-white);
  padding: clamp(40px,5vw,72px) var(--ht-gap);
  border-top: 1px solid var(--ht-sand);
}

.ht-pdp-icons__grid {
  max-width: var(--ht-max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.ht-icon-box {
  text-align: center;
  padding: 32px 24px;
  border: 1px solid var(--ht-sand);
  border-radius: var(--ht-r-lg);
  background: var(--ht-cream);
}

.ht-icon-box__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--ht-white);
  margin: 0 auto 16px;
  color: var(--ht-forest);
  box-shadow: var(--ht-shadow);
}

.ht-icon-box__title {
  font-family: var(--ht-font-display);
  font-size: 16px !important;
  font-weight: 700;
  color: var(--ht-bark);
  line-height: 1.3;
  margin-bottom: 8px;
}

.ht-icon-box__desc {
  font-size: 13px !important;
  color: var(--ht-ink);
  opacity: .7;
  line-height: 1.6;
}

/* ── Section 3: Description + Related ────────────────────────────────────── */
.ht-pdp-bottom {
  background: var(--ht-cream);
  padding: clamp(40px,5vw,80px) var(--ht-gap);
}

.ht-pdp-bottom__inner {
  max-width: var(--ht-max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.ht-pdp-desc,
.ht-pdp-related {
  min-width: 0;
}

.ht-pdp-desc__heading,
.ht-pdp-related__heading {
  font-family: var(--ht-font-display);
  font-size: clamp(20px, 2vw, 28px) !important;
  font-weight: 700;
  color: var(--ht-bark);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ht-sand);
}

.ht-pdp-desc__content {
  font-size: 15px !important;
  line-height: 1.75;
  color: var(--ht-ink);
  opacity: .85;
  margin-bottom: 28px;
}

.ht-pdp-desc__content p { margin-bottom: 14px; }

/* Attribute table */
.ht-attr-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px !important;
}

.ht-attr-table th,
.ht-attr-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--ht-sand);
  text-align: left;
}

.ht-attr-table th {
  font-weight: 600;
  color: var(--ht-bark);
  width: 40%;
  background: rgba(200,184,154,.12);
}

.ht-attr-table td { color: var(--ht-ink); }

/* ── Related Products Slider ──────────────────────────────────────────────── */
.ht-related-slider {
  position: relative;
  overflow: hidden;
}

.ht-related-track {
  display: flex;
  gap: 20px;
  transition: transform .35s ease;
}

.ht-related-item {
  flex: 0 0 calc(50% - 10px);
  min-width: 0;
}

.ht-related-item a {
  display: block;
  text-decoration: none;
  color: var(--ht-ink);
  background: var(--ht-white);
  border-radius: var(--ht-r-lg);
  overflow: hidden;
  border: 1px solid var(--ht-sand);
  transition: box-shadow .2s;
}

.ht-related-item a:hover {
  box-shadow: var(--ht-shadow-hover);
}

.ht-related-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.ht-related-item h4 {
  font-family: var(--ht-font-display);
  font-size: 15px !important;
  font-weight: 600;
  color: var(--ht-bark);
  padding: 14px 16px 4px;
}

.ht-related-price {
  font-size: 14px !important;
  font-weight: 700;
  color: var(--ht-ink);
  padding: 0 16px 8px;
}

.ht-related-cta {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ht-moss);
  padding: 0 16px 14px;
}

.ht-slider-controls {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  justify-content: flex-end;
}

.ht-slider-prev,
.ht-slider-next {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--ht-forest);
  background: transparent;
  color: var(--ht-forest);
  font-size: 18px !important;
  cursor: pointer;
  transition: background .18s, color .18s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ht-slider-prev:hover,
.ht-slider-next:hover {
  background: var(--ht-forest);
  color: var(--ht-white);
}

/* ─── ENQUIRY MODAL ───────────────────────────────────────────────────────── */
.ht-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26,26,26,.6);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  backdrop-filter: blur(3px);
}

.ht-modal-overlay[hidden] { display: none; }

.ht-modal {
  background: var(--ht-white);
  border-radius: var(--ht-r-xl);
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  padding: clamp(28px, 4vw, 48px);
  position: relative;
  box-shadow: 0 24px 80px rgba(0,0,0,.22);
  animation: ht-modal-in .22s ease;
}

@keyframes ht-modal-in {
  from { opacity: 0; transform: scale(.95) translateY(12px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.ht-modal__close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  font-size: 20px !important;
  color: var(--ht-ink);
  cursor: pointer;
  opacity: .5;
  transition: opacity .15s;
}

.ht-modal__close:hover { opacity: 1; }

.ht-modal__title {
  font-family: var(--ht-font-display);
  font-size: 22px !important;
  font-weight: 700;
  color: var(--ht-bark);
  margin-bottom: 4px;
}

.ht-modal__product-name {
  font-size: 13px !important;
  color: var(--ht-moss);
  font-weight: 600;
  margin-bottom: 24px;
}

/* Form */
.ht-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.ht-form-group label {
  font-size: 13px !important;
  font-weight: 600;
  color: var(--ht-bark);
}

.ht-form-group input,
.ht-form-group textarea {
  padding: 11px 14px;
  border: 1.5px solid var(--ht-sand);
  border-radius: var(--ht-r);
  font-family: var(--ht-font-body);
  font-size: 14px;
  color: var(--ht-ink);
  background: var(--ht-cream);
  transition: border-color .18s;
  width: 100%;
  resize: vertical;
}

.ht-form-group input:focus,
.ht-form-group textarea:focus {
  outline: none;
  border-color: var(--ht-forest);
  background: var(--ht-white);
}

.ht-btn-enquire--full {
  margin-top: 8px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════════════════ */

/* Tablet  ≤ 900px */
@media (max-width: 900px) {
  .ht-shop-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .ht-pdp-top__inner,
  .ht-pdp-bottom__inner {
    grid-template-columns: 1fr;
  }

  .ht-pdp-icons__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile ≤ 640px */
@media (max-width: 640px) {
  /* Product Details Page Text Sizes */
  .ht-pdp-title {
    font-size: 26px !important;
    line-height: 1.2;
    margin-bottom: 12px;
  }

  .ht-pdp-price {
    font-size: 20px !important;
    margin-bottom: 16px;
  }

  .ht-pdp-desc__heading,
  .ht-pdp-related__heading {
    font-size: 20px !important;
    margin-bottom: 18px;
    padding-bottom: 12px;
  }

  .ht-icon-box__title {
    font-size: 14px !important;
  }

  .ht-icon-box__desc {
    font-size: 12px !important;
  }

  /* Hero */
  .ht-shop-hero {
    grid-template-columns: 1fr;
    grid-template-rows: auto 240px;
  }

  .ht-shop-hero__content {
    padding: 36px 20px 24px;
  }

  /* Grid: 2 columns on mobile */
  .ht-shop-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .ht-product-card__name {
    font-size: 14px !important;
  }

  .ht-product-card__body {
    padding: 12px 14px 16px;
  }

  /* Icon boxes: 2×2 */
  .ht-pdp-icons__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .ht-icon-box {
    padding: 24px 16px;
  }

  /* Related: 1 per slide on mobile */
  .ht-related-item {
    flex: 0 0 85%;
  }

  /* Filter */
  .ht-shop-filter__cats {
    gap: 6px;
  }
  .ht-cat-pill {
    font-size: 12px !important;
    padding: 5px 14px;
  }
}

/* Very small ≤ 380px */
@media (max-width: 380px) {
  .ht-shop-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .ht-pdp-icons__grid {
    gap: 10px;
  }
}