/*
 * Copperwell shop design system: the home page.
 * Builds on base.css (tokens, type, buttons, product cards); see the note on isolation there.
 */

/* The page opens with its film, which starts at the very top, under the header. */
#cw .cw-home {
  padding-block: 0 clamp(56px, 7vw, 96px);
  background: var(--cw-paper);
}

/* Every part of the page sits the same distance below the one before. */
#cw .cw-homesec {
  margin-top: clamp(48px, 6vw, 88px);
}

/* The heading of a part: small line, title, and a link to more on the right. */
#cw .cw-sechead {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

#cw .cw-sechead > div {
  display: grid;
  gap: 10px;
}

#cw .cw-sechead__text {
  max-width: 60ch;
  font-size: 16px;
  line-height: 1.6;
  color: var(--cw-brown-soft);
}

#cw .cw-sechead__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 400;
  white-space: nowrap;
}

/* ---- The opening: words over a film that fills the window, as on the development site -------- */
#cw .cw-hero {
  position: relative;
  isolation: isolate;
  display: grid;
  align-items: center;
  min-height: min(960px, 94svh);
  overflow: hidden;
  background: #241a13;
  color: #fff8ee;
}

#cw .cw-hero__film {
  position: absolute;
  inset: 0;
  z-index: 0;
}

#cw .cw-hero__film video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% center;
}

/* The film is darkened from the left, where the words are, and a little along the bottom. */
#cw .cw-hero__film::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(20, 14, 9, 0.82), rgba(20, 14, 9, 0.58) 43%, rgba(20, 14, 9, 0.16) 78%),
    linear-gradient(rgba(20, 14, 9, 0) 50%, rgba(20, 14, 9, 0.3));
  pointer-events: none;
}

#cw .cw-hero__pause {
  position: absolute;
  z-index: 3;
  right: 24px;
  bottom: 24px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 248, 238, 0.3);
  border-radius: 50%;
  background: rgba(27, 20, 14, 0.72);
  color: #fff8ee;
  transition: background-color 0.2s ease;
}

#cw .cw-hero__pause:hover {
  background: var(--cw-copper);
}

#cw .cw-hero__pause:focus-visible,
#cw .cw-hero__actions :where(a):focus-visible {
  outline-color: #f6c798;
}

#cw .cw-hero__pause .cw-icon {
  fill: currentColor;
}

#cw .cw-hero__inner {
  position: relative;
  z-index: 2;
}

/* The words start below the header, which floats over the film. */
#cw .cw-hero__copy {
  display: grid;
  justify-items: start;
  gap: 28px;
  max-width: 1120px;
  padding-block: 110px 48px;
}

#cw .cw-hero__eyebrow {
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #f6c798;
}

/* Larger than any other heading of the site: this one has the whole window. */
#cw .cw-hero__title {
  font-size: clamp(44px, 5.5vw, 84px);
  line-height: 1.08;
  font-weight: 400;
  letter-spacing: -0.045em;
}

#cw .cw-hero__title > span {
  display: block;
}

#cw .cw-hero__title .cw-accent {
  letter-spacing: -0.02em;
  color: #f6c798;
}

#cw .cw-hero__lead {
  max-width: 48ch;
  font-size: 18px;
  line-height: 1.65;
}

#cw .cw-hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  margin-top: 4px;
}

#cw .cw-hero__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 15px;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
  transition: color 0.2s ease;
}

#cw .cw-hero__link:hover {
  color: #f6c798;
}

/* Three facts in a row, right under the film. */
#cw .cw-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--cw-line);
}

#cw .cw-facts > li {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 64px;
  padding: 8px 16px;
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-align: center;
  text-transform: uppercase;
  color: var(--cw-brown-soft);
}

#cw .cw-facts > li + li {
  border-left: 1px solid var(--cw-line);
}

/* ---- The six yantras, under the signature bottles (the card itself is in base.css) ------------ */
#cw [data-cw-journey-section="home-family"] .cw-show__photo[href="/product/copperwell-diamond-cup/"] .cw-show__img {
  transform: scale(0.56);
}

#cw .cw-homesec .cw-yantras {
  margin-top: 40px;
}

#cw .cw-homesec .cw-yantras__intro {
  display: grid;
  gap: 20px;
  min-width: 0;
}

#cw .cw-homesec .cw-yantras__cap {
  display: block;
  width: min(240px, 100%);
  height: auto;
  aspect-ratio: 1;
  margin-inline: auto;
  border-radius: var(--cw-radius-sm);
  object-fit: contain;
}

#cw .cw-homesec .cw-yantras__purchase {
  display: grid;
  justify-items: start;
  gap: 12px;
}

#cw .cw-homesec .cw-yantras__purchase .cw-btn {
  min-width: min(180px, 100%);
}

#cw .cw-homesec .cw-yantras__price,
#cw .cw-homesec .cw-yantras__availability {
  font-size: 14px;
  line-height: 1.5;
  color: var(--cw-brown-soft);
}

/* ---- The four rules of care: words on the left, the four pictures in a row -------------------- */
#cw .cw-care {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  align-items: center;
  gap: clamp(24px, 4vw, 64px);
  padding: clamp(24px, 4vw, 56px);
  border-radius: var(--cw-radius);
  background: var(--cw-cream);
}

#cw .cw-care__text {
  display: grid;
  justify-items: start;
  gap: 12px;
}

#cw .cw-care__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 0;
}

#cw .cw-care__rules {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px 16px;
}

#cw .cw-care__rules li {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 14px;
  font-size: 15px;
  line-height: 1.4;
  text-align: center;
  text-wrap: balance;
}

#cw .cw-care__rules img {
  width: 64px;
  height: 64px;
}

/* ---- What customers say, and what they found -------------------------------------------------- */
#cw .cw-proof {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

#cw .cw-proof__side {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: clamp(24px, 3.4vw, 48px);
  border-radius: var(--cw-radius);
  background: var(--cw-cream);
}

#cw .cw-proof__side + .cw-proof__side {
  background: var(--cw-sand);
}

#cw .cw-proof__aside {
  margin-left: 8px;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.14em;
  color: var(--cw-copper);
  white-space: nowrap;
  vertical-align: middle;
}

#cw .cw-proof__note {
  margin-top: auto;
  padding-top: 12px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--cw-brown-soft);
}

#cw .cw-quotes {
  display: grid;
  gap: 16px;
  margin-top: 12px;
}

#cw .cw-quotes__quote {
  display: grid;
  gap: 16px;
  min-height: 300px;
  align-content: start;
}

#cw .cw-quotes__photo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
}

#cw .cw-quotes blockquote {
  margin: 0;
  font-size: 18px;
  line-height: 1.6;
}

#cw .cw-quotes figcaption {
  display: grid;
  gap: 2px;
}

#cw .cw-quotes__name {
  font-size: 16px;
  font-weight: 400;
}

#cw .cw-quotes__place {
  font-size: 13px;
  color: var(--cw-brown-soft);
}

#cw .cw-quotes__nav {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--cw-brown-soft);
  font-variant-numeric: tabular-nums;
}

#cw .cw-quotes__nav .cw-iconbtn {
  border: 1px solid var(--cw-line-strong);
}

#cw .cw-results {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

#cw .cw-results li {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 14px 20px;
  border-radius: var(--cw-radius-sm);
  background: var(--cw-paper);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 400;
}

#cw .cw-results__figure {
  min-width: 92px;
  font-size: 36px;
  line-height: 1;
  font-weight: 300;
  font-variant-numeric: tabular-nums;
}

#cw .cw-results__label {
  display: block;
  font-size: 13px;
  font-weight: 400;
  color: var(--cw-brown-soft);
}

/* ---- The morning ritual: four steps beside the film ------------------------------------------- */
#cw .cw-ritual {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: clamp(24px, 4vw, 64px);
  scroll-margin-top: var(--cw-header);
}

#cw .cw-ritual__text {
  display: grid;
  gap: 10px;
}

#cw .cw-ritual .cw-steps {
  margin-top: 18px;
}

#cw .cw-ritual__media {
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: var(--cw-radius);
  background: #1a120a;
}

#cw .cw-ritual__media video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---- The experts -------------------------------------------------------------------------------- */
#cw .cw-experts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

#cw .cw-experts li {
  display: grid;
  grid-template-columns: 38% minmax(0, 1fr);
  overflow: hidden;
  border-radius: var(--cw-radius);
  background: var(--cw-cream);
}

#cw .cw-experts img {
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

#cw .cw-experts li > div {
  padding: 24px;
}

#cw .cw-experts__name {
  font-size: 18px;
  line-height: 1.35;
  font-weight: 400;
}

#cw .cw-experts__role {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.5;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cw-copper);
}

#cw .cw-experts__text {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--cw-brown-soft);
}

/* ---- What the bottle stands for: a dark band --------------------------------------------------- */
#cw .cw-band {
  padding: clamp(32px, 4vw, 56px);
  border-radius: var(--cw-radius);
  background: var(--cw-brown);
  color: #fff;
  text-align: center;
}

/* On the dark band the accent is drawn in the light copper tone. */
#cw .cw-band .cw-accent {
  color: var(--cw-peach);
}

#cw .cw-band ul {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 24px;
  margin-top: 36px;
}

#cw .cw-band li {
  display: grid;
  justify-items: center;
  gap: 14px;
  font-size: 13px;
  line-height: 1.4;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

#cw .cw-band img {
  width: 64px;
  height: 64px;
}

@media (max-width: 900px) {
  #cw .cw-care,
  #cw .cw-proof,
  #cw .cw-ritual,
  #cw .cw-experts {
    grid-template-columns: minmax(0, 1fr);
  }

  #cw .cw-band ul {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #cw .cw-care__rules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #cw .cw-quotes__quote {
    min-height: 0;
  }

  #cw .cw-ritual__media {
    max-width: 520px;
  }
}

@media (max-width: 560px) {
  #cw .cw-sechead {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  #cw .cw-band ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #cw .cw-results li {
    gap: 14px;
    padding: 12px 16px;
    font-size: 16px;
  }

  #cw .cw-results__figure {
    min-width: 76px;
  }

  #cw .cw-experts li {
    grid-template-columns: 34% minmax(0, 1fr);
  }

  #cw .cw-experts li > div {
    padding: 18px;
  }
}

@media (max-width: 767px) {
  #cw .cw-hero {
    min-height: max(700px, 92svh);
  }

  #cw .cw-hero__film video {
    object-position: 62% center;
  }

  #cw .cw-hero__film::after {
    background:
      linear-gradient(90deg, rgba(20, 14, 9, 0.76), rgba(20, 14, 9, 0.38)),
      linear-gradient(rgba(20, 14, 9, 0), rgba(20, 14, 9, 0.65));
  }

  #cw .cw-hero__copy {
    gap: 24px;
    padding-block: 104px 64px;
  }

  #cw .cw-hero__title {
    font-size: clamp(39px, 10vw, 64px);
    line-height: 1.12;
  }

  #cw .cw-hero__lead {
    max-width: 34ch;
    font-size: 16px;
  }

  #cw .cw-hero__pause {
    right: 16px;
    bottom: 16px;
  }

  #cw .cw-facts {
    grid-template-columns: minmax(0, 1fr);
  }

  #cw .cw-facts > li {
    min-height: 52px;
  }

  #cw .cw-facts > li + li {
    border-top: 1px solid var(--cw-line);
    border-left: 0;
  }
}
