/* ============================================================================
   Homepage sections
   ========================================================================== */

/* --- shared -------------------------------------------------------------- */
.k4l-sectionhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}
.k4l-sectionhead .k4l-h2 { margin: 0; }

/* --- 1. hero ------------------------------------------------------------- */
.k4l-hero { background: var(--k4l-grey-bg); padding-block: clamp(32px, 4vw, 56px); }

.k4l-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  align-items: stretch;
}

.k4l-hero__main {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  /* Source hero section measures 730px tall at 1440; keep the render and the
     card rail on the same rhythm rather than letting the display type dictate it. */
  min-height: 620px;
}

.k4l-hero__title {
  margin: 0 0 20px;
  font-size: var(--k4l-fs-hero);
  line-height: .88;
  letter-spacing: -.02em;
}
.k4l-hero__line { display: block; color: var(--k4l-purple); }
.k4l-hero__line--alt { color: var(--k4l-purple-tint); }

.k4l-hero__lede {
  max-width: 44ch;
  font-size: var(--k4l-fs-lg);
  color: var(--k4l-ink-80);
  margin-bottom: 28px;
}

.k4l-hero__stage { position: relative; width: 373px; height: 373px; justify-self: end; }
.k4l-hero__render {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity .45s ease;
}
.k4l-hero__render.is-active { opacity: 1; }

/* right rail of feature cards */
.k4l-hero__rail { display: flex; flex-direction: column; gap: 16px; }

.k4l-herocard {
  display: block;
  background: var(--k4l-white);
  border-radius: var(--k4l-radius-lg);
  padding: 24px;
  color: var(--k4l-ink);
  box-shadow: var(--k4l-shadow);
  transition: box-shadow .2s ease, transform .2s ease;
  flex: 1;
}
.k4l-herocard:hover { box-shadow: var(--k4l-shadow-lg); transform: translateY(-2px); }

.k4l-herocard__title { font-size: var(--k4l-fs-h3); margin-bottom: 8px; color: var(--k4l-ink); }
.k4l-herocard.is-active .k4l-herocard__title { color: var(--k4l-purple-light); }

.k4l-herocard__text { font-size: var(--k4l-fs-base); color: var(--k4l-ink-60); margin: 0; }

/* --- 2. social proof ----------------------------------------------------- */
.k4l-social__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 48px;
  align-items: center;
}

.k4l-social__sub { font-size: var(--k4l-fs-lg); color: rgba(255, 255, 255, .88); margin: 0; }

.k4l-social__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

.k4l-platform {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 108px;
  padding: 24px 28px;
  background: var(--k4l-white);
  border-radius: var(--k4l-radius-lg);
  transition: transform .2s ease;
}
.k4l-platform:hover { transform: translateY(-3px); }
.k4l-platform img { max-height: 60px; width: auto; object-fit: contain; }

.k4l-platform__arrow { position: absolute; top: 14px; right: 14px; color: var(--k4l-purple); }
.k4l-platform__arrow svg { width: 18px; height: 18px; }

/* --- 3. carousels -------------------------------------------------------- */
.k4l-carousel { overflow: hidden; }

.k4l-carousel__track {
  display: flex;
  gap: 24px;
  scroll-snap-type: x mandatory;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding-bottom: 8px;
  scrollbar-width: none;
}
.k4l-carousel__track::-webkit-scrollbar { display: none; }

.k4l-carousel__slide {
  flex: 0 0 calc((100% - 72px) / 4);
  scroll-snap-align: start;
}

.k4l-carousel__nav { display: flex; gap: 10px; }
.k4l-carousel__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--k4l-purple);
  cursor: pointer;
  transition: background .18s ease;
}
.k4l-carousel__btn:hover { background: var(--k4l-purple-wash); }

/* --- product card (shared: home best-sellers · shop grid · PDP related) ----
   Measured 1:1 off the source Bricks loop card (source-cdp/shop/card-styles.json).
   Card: #F5F5F5, radius 8px, padding 24px, Public Sans 300, ink #0E0816.        */
.k4l-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--k4l-grey-bg);          /* #F5F5F5 */
  border-radius: 8px;
  padding: 24px;
  font-family: var(--k4l-font-body);
  font-weight: 300;
  color: var(--k4l-ink);
}

/* unit-price pill — left-attached tab at the card edge, aligned to image top.
   Source: bg #372480, white, Public Sans 16/600, radius 2px 10px 10px 2px.      */
.k4l-card__unit {
  position: absolute;
  top: 24px;
  left: 0;
  z-index: 2;
  background: var(--k4l-purple);
  color: var(--k4l-white);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.15;
  padding: 4px 6px;
  border-radius: 2px 10px 10px 2px;
  white-space: nowrap;
}

.k4l-card__media { position: static; display: block; border-radius: 4px; overflow: hidden; }
.k4l-card__media img,
.k4l-card__img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 4px; display: block; }

.k4l-card__info { display: flex; flex-direction: column; gap: 8px; flex: 1; padding-top: 16px; }

.k4l-card__head { display: flex; flex-direction: column; gap: 6px; }

.k4l-card__title {
  font-family: var(--k4l-font-display);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0;
}
.k4l-card__title a { color: var(--k4l-ink); }
.k4l-card__title a:hover { color: var(--k4l-purple-mid); }

.k4l-card__spec { font-size: 13px; font-weight: 300; color: var(--k4l-ink); margin: 0; line-height: 1.35; }

/* buy box — white, radius 4px, padding 8/16, label+price left · cart button right.
   min-height matches the source's measured box height (h=68 in BOTH stock states,
   set by the 48px cart button + 8px vertical padding). Giving the sold-out box the
   same min-height keeps every card's buy box aligned at the bottom uniformly. */
.k4l-card__buy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  min-height: 68px;
  background: var(--k4l-white);
  border-radius: 4px;
  padding: 8px 16px;
}

.k4l-card__buyleft { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

.k4l-card__buylabel,
.k4l-card__wishlabel { font-size: 14px; font-weight: 300; color: var(--k4l-ink); }
.k4l-card__wishlabel:hover { color: var(--k4l-purple-mid); }

.k4l-card__price {
  font-family: var(--k4l-font-display);
  font-size: 20px;
  font-weight: 600;
  color: var(--k4l-purple);            /* regular / in-stock price */
  line-height: 1.2;
}
.k4l-card__price .price { margin: 0; color: inherit; }
/* on sale: current price GREEN, original strikethrough GREY — NO red badge */
.k4l-card__price del,
.k4l-card__price del .amount {
  color: var(--k4l-grey-3);
  font-family: var(--k4l-font-body);
  font-size: 16px;
  font-weight: 600;
  text-decoration: line-through;
  margin-right: 5px;
}
.k4l-card__price ins,
.k4l-card__price ins .amount { color: var(--k4l-green); text-decoration: none; }

/* square cart button — 48px, #372480, radius 8px, white glyph */
.k4l-card__cart {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 12px;
  background: var(--k4l-purple);
  border-radius: 8px;
  color: var(--k4l-white);
  transition: background .18s ease;
}
.k4l-card__cart:hover { background: var(--k4l-purple-mid); }
.k4l-card__cart.loading { opacity: .6; pointer-events: none; }
.k4l-card__cart.added::after { content: none; }
.k4l-card__cart svg { width: 24px; height: 24px; display: block; }
/* WooCommerce auto-appends a "View cart" link after an AJAX add — the drawer
   replaces that affordance, so hide it inside the card. */
.k4l-card .added_to_cart { display: none !important; }

/* sold out: "Sold Out" text (#372480) in place of the cart button */
.k4l-card__soldout {
  flex: none;
  font-size: 18px;
  font-weight: 600;
  color: var(--k4l-purple);
  font-family: var(--k4l-font-body);
}
.k4l-card--oos .k4l-card__media img { opacity: .78; }

/* --- 4. explore / category tiles ----------------------------------------- */
.k4l-explore__inner {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}
.k4l-explore__copy .k4l-h2 { margin-bottom: 20px; }

.k4l-explore__grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }

.k4l-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 18px 10px;
  border-radius: var(--k4l-radius-lg);
  color: var(--k4l-ink);
  text-align: center;
  transition: background .2s ease, transform .2s ease;
}
.k4l-tile:hover { background: var(--k4l-purple-wash); transform: translateY(-2px); color: var(--k4l-purple); }

.k4l-tile__icon { height: 100px; width: auto; object-fit: contain; }
.k4l-tile__label { font-size: var(--k4l-fs-sm); font-weight: 600; line-height: 1.25; }

/* --- 5. video wall ------------------------------------------------------- */
.k4l-videos__title { margin-bottom: 32px; }

.k4l-videos__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

.k4l-videos__cell {
  border-radius: var(--k4l-radius-lg);
  overflow: hidden;
  background: var(--k4l-ink);
  aspect-ratio: 16 / 10;
}
.k4l-videos__video { width: 100%; height: 100%; object-fit: cover; }

/* --- 6. value props ------------------------------------------------------ */
.k4l-why__inner {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}
.k4l-why__title { margin: 0; }

.k4l-why__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }

.k4l-prop__title { font-size: var(--k4l-fs-h4); margin-bottom: 12px; }
.k4l-prop__text { color: var(--k4l-ink-60); margin: 0; }

/* --- 7. about ------------------------------------------------------------ */
.k4l-about__inner {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}
.k4l-about__title { margin: 0; }
.k4l-about__lede { font-size: var(--k4l-fs-lg); font-weight: 600; }
.k4l-about__body p { color: var(--k4l-ink-80); }
.k4l-about__tag {
  font-family: var(--k4l-font-display);
  font-size: var(--k4l-fs-h4);
  font-weight: 600;
  color: var(--k4l-purple);
  margin-top: 24px;
}

/* --- 8. image band ------------------------------------------------------- */
.k4l-band { position: relative; overflow: hidden; }
.k4l-band__img { width: 100%; height: clamp(320px, 40vw, 620px); object-fit: cover; display: block; }
.k4l-band__mark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(300px, 30vw);
}

/* --- 9. written testimonials --------------------------------------------- */
.k4l-quotes__title { margin-bottom: 36px; }
.k4l-quotes__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }

.k4l-quote {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 0;
  padding: 28px;
  background: var(--k4l-white);
  border: 1px solid var(--k4l-border);
  border-radius: var(--k4l-radius-lg);
}
.k4l-quote__text { margin: 0; font-size: var(--k4l-fs-base); color: var(--k4l-ink-80); line-height: 1.65; }
.k4l-quote__meta { display: flex; align-items: center; gap: 10px; margin-top: auto; }
.k4l-quote__author { font-family: var(--k4l-font-display); font-weight: 600; }
.k4l-quote__source {
  font-size: var(--k4l-fs-xs);
  font-weight: 700;
  color: var(--k4l-purple);
  background: var(--k4l-purple-wash);
  padding: 3px 9px;
  border-radius: 999px;
}

/* --- 10. FAQ ------------------------------------------------------------- */
.k4l-faq__title { margin-bottom: 32px; }
.k4l-faq__list { max-width: 900px; margin-inline: auto; }

.k4l-faq__item { border-bottom: 1px solid var(--k4l-border); }

.k4l-faq__q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 0;
  font-family: var(--k4l-font-display);
  font-size: var(--k4l-fs-h3);
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.k4l-faq__q::-webkit-details-marker { display: none; }
.k4l-faq__q:hover { color: var(--k4l-purple); }

.k4l-faq__sign { position: relative; flex: none; width: 20px; height: 20px; }
.k4l-faq__sign::before,
.k4l-faq__sign::after {
  content: "";
  position: absolute;
  background: var(--k4l-purple);
  border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}
.k4l-faq__sign::before { top: 9px; left: 0; width: 20px; height: 2px; }
.k4l-faq__sign::after  { left: 9px; top: 0; width: 2px; height: 20px; }
.k4l-faq__item[open] .k4l-faq__sign::after { transform: rotate(90deg); opacity: 0; }

.k4l-faq__a { padding: 0 0 22px; max-width: 78ch; color: var(--k4l-ink-60); }
.k4l-faq__a p { margin: 0; }

.k4l-faq__cta { text-align: center; margin-top: 48px; }
.k4l-faq__ctatitle { font-size: var(--k4l-fs-h4); margin-bottom: 16px; }

/* --- responsive ---------------------------------------------------------- */
@media (max-width: 1200px) {
  .k4l-carousel__slide { flex-basis: calc((100% - 48px) / 3); }
  .k4l-explore__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 991px) {
  .k4l-hero__inner { grid-template-columns: 1fr; }
  .k4l-hero__main { grid-template-columns: 1fr; min-height: 0; text-align: left; }
  .k4l-hero__stage { justify-self: center; width: min(320px, 70vw); height: auto; aspect-ratio: 1; }
  .k4l-hero__rail { flex-direction: row; overflow-x: auto; }
  .k4l-herocard { min-width: 260px; }

  .k4l-social__inner { grid-template-columns: 1fr; gap: 32px; }
  .k4l-explore__inner,
  .k4l-why__inner,
  .k4l-about__inner { grid-template-columns: 1fr; gap: 28px; }
  .k4l-why__grid { grid-template-columns: 1fr; gap: 24px; }

  .k4l-videos__grid { grid-template-columns: repeat(2, 1fr); }
  .k4l-quotes__grid { grid-template-columns: 1fr; }
  .k4l-carousel__slide { flex-basis: calc((100% - 24px) / 2); }
}

@media (max-width: 600px) {
  .k4l-carousel__slide { flex-basis: 78%; }
  .k4l-explore__grid { grid-template-columns: repeat(2, 1fr); }
  .k4l-videos__grid { grid-template-columns: 1fr; }
  .k4l-social__grid { grid-template-columns: 1fr; }
  .k4l-sectionhead { flex-direction: column; align-items: flex-start; gap: 12px; }
}
