/* ============================================================
   Cooprtim 2.0 — homepage
   Layout lives in store.css (the concept system). This file only
   adds what the WordPress templates need on top of it.
   ============================================================ */

/* Reveal states: hidden only when JS is running, so no-JS users see content. */
.js .cooprtim-home .rv {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 70ms);
  will-change: opacity, transform;
}
.js .cooprtim-home .rv.is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .js .cooprtim-home .rv { opacity: 1; transform: none; transition: none; }
}

/* Filtered cards must actually disappear. */
.cooprtim-home .pk[hidden],
.cooprtim-home .pcard[hidden] { display: none !important; }

/* Catalog cards: real product images are photos, not cut-outs. */
.cooprtim-home .grid .pk__media img { width: 100%; height: 100%; object-fit: contain; }

/* Pack cards keep their cover fill. */
.cooprtim-home .pcard__media img { width: 100%; height: 100%; object-fit: contain; }

/* Load-more busy state. */
.cooprtim-home [data-cat-more].is-loading { opacity: .55; pointer-events: none; }

/* The builder tray is inert until Phase 3 wires it to PackBuilder. */
.cooprtim-home .tray [data-pack-cta][disabled] { opacity: .8; cursor: default; }

/* Hero sits under the fixed header: keep its existing top padding but make sure
   the homepage never gets the inner-page offset. */
.cooprtim-front .cooprtim-content { padding-block-start: 0; }

/* Tabs need to scroll horizontally on small screens instead of wrapping badly. */
@media (max-width: 720px) {
  .cooprtim-home .cat__tabs {
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding-block-end: .4rem;
  }
  .cooprtim-home .cat__tabs::-webkit-scrollbar { display: none; }
  .cooprtim-home .cat__tabs .ctab { flex: 0 0 auto; }
  .cooprtim-home .pkfilter { overflow-x: auto; scrollbar-width: none; }
  .cooprtim-home .pkfilter::-webkit-scrollbar { display: none; }
}

/* ---------- contrast fixes (hero strip + header nav) ---------- */
/* The tier strip carries white type; it needs the dark base behind it. */
.cooprtim-front .hx-tiers {
  background: linear-gradient(180deg, rgba(18, 59, 37, .97), rgba(14, 47, 28, .99));
  color: #f6efe3;
  box-shadow: 0 22px 44px -34px rgba(10, 30, 18, .9);
}
.cooprtim-front .hx-tier__qty { color: rgba(246, 239, 227, .72); }
.cooprtim-front .hx-tier__val { color: #f6efe3; }
.cooprtim-front .hx-tier__val i { color: rgba(246, 239, 227, .72); }
.cooprtim-front .hx-tier.is-on .hx-tier__qty,
.cooprtim-front .hx-tier.is-on .hx-tier__val,
.cooprtim-front .hx-tier.is-on .hx-tier__val i { color: #14290f; }
.cooprtim-front .hx-tier.is-on .hx-tier__ico { color: #14290f; }

/* Nav sits on the hero photograph: use the ink colour, not the accent. */
.cooprtim-front .hd .nav a,
.hd .nav a { color: #142c1c; }

/* Brand text stays legible over the light hero. */
.cooprtim-front .hd .brand__txt b,
.cooprtim-front .hd .brand__txt i { color: #142c1c; }

/* Transparent-header nav reads too light over the hero photograph. */
.cooprtim-front .hd .nav,
.cooprtim-front .hd .nav a,
.cooprtim-front .hd .tool,
.cooprtim-front .hd .cart { opacity: 1; }
.cooprtim-front .hd .nav a { color: #142c1c; font-weight: 600; }
.cooprtim-front .hd .tool,
.cooprtim-front .hd .cart { color: #142c1c; }

/* ---------- builder tray slots ---------- */
.cooprtim-home .tray__prog { height: 5px; border-radius: 4px; background: rgba(18, 59, 37, .1); overflow: hidden; }
.cooprtim-home .tray__prog i { display: block; height: 100%; width: 0; background: var(--gold); transition: width .35s var(--ease); }
.cooprtim-home [data-pack-cta].is-ready { background: var(--forest); }

/* ---------- drawer: pack badges + per-pack discounts ---------- */
.drawer__pack {
  display: inline-block;
  margin-top: .15rem;
  padding: .1rem .4rem;
  border-radius: 4px;
  font-size: .62rem;
  letter-spacing: .04em;
  color: var(--forest);
  background: rgba(18, 59, 37, .08);
}
.drawer__fees { margin: .9rem 0 0; padding: 0; list-style: none; border-top: 1px dashed rgba(18, 59, 37, .16); }
.drawer__fee { display: flex; justify-content: space-between; gap: 1rem; padding: .45rem 0 0; font-size: .78rem; color: var(--forest); }
.drawer__fee b { color: var(--gold-deep, #8a6a1f); }

/* ---------- Google reviews (Trustindex) ---------- */
.reviews {
  background: var(--cream);
  padding-block: clamp(2.8rem, 5vw, 5rem);
  border-block-start: 1px solid var(--line);
}
.reviews__head {
  display: flex; flex-direction: column; align-items: center; gap: .7rem;
  text-align: center; margin-block-end: clamp(1.4rem, 2.4vw, 2.2rem);
}
.reviews__head .eyebrow { justify-content: center; }
.reviews__lead { color: var(--muted); font-size: .92rem; max-width: 48ch; }

/* Server-rendered widget: the reserved height keeps the CTA from jumping. */
.reviews__widget { min-height: 320px; }
.reviews__widget .ti-widget { margin-inline: auto; max-width: 100%; }
.reviews__widget .ti-widget img { height: auto; }

.reviews__foot { display: flex; justify-content: center; margin-block-start: clamp(1.2rem, 2vw, 1.8rem); }

@media (max-width: 620px) {
  .reviews__widget { min-height: 280px; }
  .reviews__widget .ti-widget { --ti-review-item-width: 100%; }
}

/* The ghost button is built for dark sections; on the cream reviews band it
   needs ink-coloured text and a visible hairline. */
.reviews .btn.btn--ghost {
  --fg-btn: var(--forest);
  color: var(--forest);
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--line-2), 0 16px 30px -24px rgba(18, 59, 37, .55);
}
.reviews .btn.btn--ghost:hover {
  color: var(--forest);
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--forest), 0 20px 34px -24px rgba(18, 59, 37, .6);
}
