/* ==========================================================
   PURCHASE — Styles (refactored + organized)
   What this file covers:
   1) Theme: Light “Parchment + Ember Glow” section background
   2) Cards: warm glass surfaces + typography
   3) CTA: Victoria-Register style button (square outline + center fill)
   4) A11y: focus-visible + reduced motion
   5) Fix: remove unwanted text-shadow on subhead + prices
   ========================================================== */


/* ==========================================================
   0) MOBILE: hide book details panel (per your earlier rule)
   ========================================================== */
@media (max-width: 980px){
  #purchase .about-book-img .book-details{
    display: none !important;
  }
}


/* ==========================================================
   1) SECTION THEME: Light “Parchment + Ember Glow”
   ========================================================== */
#purchase.purchase{
  position: relative;
  isolation: isolate;
  overflow: hidden;

  /* kill template light background so our custom bg shows */
  background: transparent !important;
}

#purchase.purchase::before{
  content:"";
  position:absolute;
  inset:-18%;
  z-index:-2;
  pointer-events:none;

  background:
    /* ember glows */
    radial-gradient(900px 520px at 18% 30%,
      rgba(255, 140, 50, 0.22),
      rgba(255, 140, 50, 0) 60%),
    radial-gradient(760px 520px at 82% 36%,
      rgba(255, 70, 20, 0.18),
      rgba(255, 70, 20, 0) 62%),
    radial-gradient(980px 700px at 55% 78%,
      rgba(255, 215, 140, 0.22),
      rgba(255, 215, 140, 0) 65%),

    /* parchment base */
    linear-gradient(135deg,
      rgba(255, 248, 236, 0.98) 0%,
      rgba(255, 242, 224, 0.98) 35%,
      rgba(252, 236, 218, 0.98) 65%,
      rgba(248, 228, 206, 0.99) 100%);

  filter: blur(10px) saturate(112%);
}

#purchase.purchase::after{
  content:"";
  position:absolute;
  inset:-12%;
  z-index:-2;
  pointer-events:none;

  /* subtle grain / smoke */
  background:
    radial-gradient(900px 520px at 35% 45%,
      rgba(60, 30, 20, 0.06),
      rgba(60, 30, 20, 0) 62%),
    radial-gradient(700px 520px at 65% 55%,
      rgba(60, 30, 20, 0.05),
      rgba(60, 30, 20, 0) 60%);

  filter: blur(18px);
  opacity: 0.75;
}


/* ==========================================================
   2) SECTION TITLE: readable on light background
   ========================================================== */
#purchase.purchase .section-title h2{
  color: rgba(26, 18, 14, 0.92) !important;
  text-shadow: 0 2px 14px rgba(255,255,255,0.65) !important;
}

#purchase.purchase .section-title p{
  color: rgba(45, 28, 20, 0.70) !important;
  text-shadow: none !important; /* user request */
}


/* ==========================================================
   3) CARDS: warm glass + ink text
   ========================================================== */
#purchase.purchase .book-format-card{
  background: rgba(255, 248, 240, 0.58) !important;
  border: 1px solid rgba(90, 40, 25, 0.14) !important;
  box-shadow: 0 22px 55px rgba(30,16,10,0.18) !important;

  -webkit-backdrop-filter: blur(14px) saturate(118%) !important;
  backdrop-filter: blur(14px) saturate(118%) !important;
}

#purchase.purchase .book-format-card h3{
  color: rgba(24, 16, 12, 0.92) !important;
}

#purchase.purchase .book-format-card .format-features li{
  color: rgba(32, 20, 14, 0.78) !important;
}

/* price: ember but NO shadow (user request) */
#purchase.purchase .book-format-card .format-price{
  color: color-mix(in srgb, var(--accent-color), #a14a22 25%) !important;
  text-shadow: none !important;
}

/* icon circle */
#purchase.purchase .book-format-card .format-icon{
  background: rgba(255, 140, 50, 0.10) !important;
  border: 1px solid rgba(255, 120, 40, 0.18) !important;
}

#purchase.purchase .book-format-card .format-icon i{
  color: color-mix(in srgb, var(--accent-color), #7a2b10 25%) !important;
}

/* bullet icons */
#purchase.purchase .book-format-card .format-features li i{
  color: color-mix(in srgb, var(--accent-color), #7a2b10 20%) !important;
}


/* ==========================================================
   4) CTA BUTTON: Victoria Register (square, transparent, fill on hover)
   Add class to links: .btn-purchase.purchase-cta-victoria
   ========================================================== */
#purchase.purchase .buy-options{
  display: flex;
  justify-content: center;
}

/* base button */
#purchase.purchase .btn-purchase.purchase-cta-victoria{
  all: unset;
  box-sizing: border-box;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;

  padding: 14px 18px;
  min-height: 46px;
  min-width: 240px;

  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  line-height: 1;

  /* readable on light card */
  color: rgba(28, 18, 12, 0.90) !important;
  background: rgba(255,255,255,0.45) !important;

  border: 2px solid color-mix(in srgb, var(--accent-color), #7a2b10 25%) !important;
  border-radius: 0 !important;

  position: relative;
  overflow: hidden;
  z-index: 0;

  cursor: pointer;
  text-decoration: none;

  box-shadow: 0 10px 26px rgba(30,16,10,0.14) !important;
  transition: transform .25s ease, color .35s ease, box-shadow .35s ease, border-color .35s ease;
}

/* optional icon alignment */
#purchase.purchase .btn-purchase.purchase-cta-victoria i{
  font-size: 1rem;
  line-height: 1;
  vertical-align: -1px;
}

/* victoria “register” center-fill */
#purchase.purchase .btn-purchase.purchase-cta-victoria::after{
  content:"";
  position:absolute;
  left: 50%;
  top: 50%;
  width: 150%;
  height: 0%;
  background: var(--accent-color) !important;

  transform: translate(-50%, -50%);
  opacity: .55;
  z-index: -1;

  transition: height .75s ease, opacity .75s ease;
}

/* hover/focus */
#purchase.purchase .btn-purchase.purchase-cta-victoria:hover,
#purchase.purchase .btn-purchase.purchase-cta-victoria:focus-visible{
  transform: translateY(-1px);
  color: #fff !important;

  box-shadow:
    0 14px 34px rgba(30,16,10,0.18),
    0 0 22px rgba(255, 180, 90, 0.14),
    0 0 42px rgba(255, 65, 0, 0.10);
}

#purchase.purchase .btn-purchase.purchase-cta-victoria:hover::after,
#purchase.purchase .btn-purchase.purchase-cta-victoria:focus-visible::after{
  height: 140%;
  opacity: 1;
}

/* focus ring */
#purchase.purchase .btn-purchase.purchase-cta-victoria:focus-visible{
  outline: 2px solid color-mix(in srgb, var(--accent-color), white 35%);
  outline-offset: 3px;
}

/* reduced motion */
@media (prefers-reduced-motion: reduce){
  #purchase.purchase .btn-purchase.purchase-cta-victoria,
  #purchase.purchase .btn-purchase.purchase-cta-victoria::after{
    transition: none !important;
  }
  #purchase.purchase .btn-purchase.purchase-cta-victoria::after{
    display:none;
  }
  #purchase.purchase .btn-purchase.purchase-cta-victoria:hover,
  #purchase.purchase .btn-purchase.purchase-cta-victoria:focus-visible{
    transform: none;
    background: var(--accent-color) !important;
    color: #fff !important;
  }
}

/* ==========================================================
   PURCHASE — secondary excerpt CTA
   ========================================================== */

#purchase .purchase-secondary-cta{
  margin-top: 2rem;
}

#purchase .purchase-secondary-copy{
  margin: 0 0 0.9rem;
  font-size: 1rem;
  line-height: 1.5;
  opacity: 0.9;
}

#purchase .purchase-cta-secondary{
  min-width: 220px;
}

/* ==========================================================
   PURCHASE — secondary excerpt CTA
   ========================================================== */

#purchase .purchase-secondary-cta{
  position: relative;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
}

#purchase .purchase-secondary-cta::before{
  content: "";
  display: block;
  width: 4.5rem;
  height: 1px;
  margin: 0 auto 1.1rem;
  background: linear-gradient(
    90deg,
    rgba(196, 94, 40, 0),
    rgba(196, 94, 40, 0.75),
    rgba(196, 94, 40, 0)
  );
}

#purchase .purchase-secondary-copy{
  margin: 0 0 1.1rem;
  font-size: clamp(1.05rem, 0.98rem + 0.35vw, 1.3rem);
  line-height: 1.45;
  color: #3b312b;
}

#purchase .purchase-secondary-lead{
  display: block;
  margin-bottom: 0.2rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--heading-color);
}

#purchase .purchase-secondary-follow{
  display: block;
  opacity: 0.92;
}

#purchase .purchase-cta-secondary{
  min-width: 240px;
}

@media (max-width: 575.98px){
  #purchase .purchase-secondary-cta{
    margin-top: 2rem;
    padding-top: 1.25rem;
  }

  #purchase .purchase-secondary-copy{
    font-size: 1.05rem;
  }

  #purchase .purchase-cta-secondary{
    min-width: 0;
    width: 100%;
    max-width: 20rem;
  }
}

#purchase .purchase-secondary-lead{
  display: block;
  margin-bottom: 0.35rem;
  font-size: clamp(1.15rem, 1.02rem + 0.45vw, 1.45rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--heading-color);
}


/* ==========================================================
   PURCHASE — section shell + decorative map background
   ========================================================== */

#purchase.purchase{
  position: relative;
  overflow: hidden;
}

#purchase .purchase-map-bg{
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

#purchase .purchase-map-bg img{
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  opacity: 0.28;

  -webkit-mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.14) 0%,
    rgba(0, 0, 0, 0.58) 20%,
    rgba(0, 0, 0, 0.85) 45%,
    rgba(0, 0, 0, 1) 70%,
    rgba(0, 0, 0, 1) 100%
  );
  mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.14) 0%,
    rgba(0, 0, 0, 0.58) 20%,
    rgba(0, 0, 0, 0.85) 45%,
    rgba(0, 0, 0, 1) 70%,
    rgba(0, 0, 0, 1) 100%
  );
}

/* Keep real content above the decorative map */
#purchase > .container,
#purchase > .purchase-secondary-cta{
  position: relative;
  z-index: 2;
}


/* ==========================================================
   PURCHASE — section title / meta line
   ========================================================== */

#purchase .purchase-meta-label{
  font-weight: 700;
  color: var(--heading-color);
}

#purchase .purchase-meta-price{
  font-weight: 700;
  color: var(--heading-color);
}

#purchase .purchase-meta-sep{
  opacity: 0.65;
  margin: 0 0.25rem;
}


/* ==========================================================
   PURCHASE CARDS — title, price, list, button alignment
   ========================================================== */

/* Retailer title */
#purchase .book-format-card h3{
  font-size: clamp(1.85rem, 1.55rem + 0.6vw, 2.3rem);
  line-height: 1.1;
  margin-bottom: 0.55rem;
}

/* Price */
#purchase .book-format-card .format-price{
  font-size: clamp(2rem, 1.7rem + 0.7vw, 2.6rem);
  line-height: 1;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

/* Feature list */
#purchase .book-format-card .format-features{
  list-style: none;
  padding: 0;
  margin: 0 auto 1.85rem;
  width: min(100%, 18.5rem);
}

#purchase .book-format-card .format-features li{
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: clamp(1rem, 0.95rem + 0.18vw, 1.12rem);
  line-height: 1.45;
  margin-bottom: 0.9rem;
}

#purchase .book-format-card .format-features li i{
  flex: 0 0 auto;
  font-size: 1.05rem;
  line-height: 1;
  margin-top: 0.22rem;
}

/* Keep CTA aligned to same width as feature list */
#purchase .book-format-card .buy-options{
  width: min(100%, 18.5rem);
  margin: 0 auto;
}

#purchase .book-format-card .buy-options .btn-purchase{
  width: 100%;
  justify-content: center;
}


/* ==========================================================
   PURCHASE — secondary excerpt CTA
   ========================================================== */

#purchase .purchase-secondary-cta{
  margin-top: 2.5rem;
  padding-top: 0;
}

#purchase .purchase-secondary-copy{
  margin: 0 0 1.1rem;
  color: #3b312b;
}

#purchase .purchase-secondary-cta .purchase-secondary-copy .purchase-secondary-lead{
  display: block;
  margin-bottom: 0.35rem;
  font-size: clamp(1.2rem, 1.05rem + 0.45vw, 1.5rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--heading-color);
}

#purchase .purchase-secondary-cta .purchase-secondary-copy .purchase-secondary-follow{
  display: block;
  font-size: clamp(1rem, 0.95rem + 0.2vw, 1.12rem);
  line-height: 1.45;
  opacity: 0.92;
}

#purchase .purchase-cta-secondary{
  min-width: 240px;
}


/* ==========================================================
   PURCHASE — responsive adjustments
   ========================================================== */

@media (max-width: 991.98px){
  #purchase .purchase-map-bg img{
    opacity: 0.10;
  }
}

@media (max-width: 575.98px){
  #purchase .purchase-secondary-cta{
    margin-top: 2rem;
  }

  #purchase .purchase-secondary-cta .purchase-secondary-copy .purchase-secondary-lead{
    font-size: 1.15rem;
  }

  #purchase .purchase-secondary-cta .purchase-secondary-copy .purchase-secondary-follow{
    font-size: 1rem;
  }

  #purchase .purchase-cta-secondary{
    min-width: 0;
    width: 100%;
    max-width: 20rem;
  }

  #purchase .book-format-card h3{
    font-size: clamp(1.65rem, 1.45rem + 0.5vw, 1.95rem);
  }

  #purchase .book-format-card .format-price{
    font-size: clamp(1.8rem, 1.55rem + 0.5vw, 2.15rem);
  }

  #purchase .book-format-card .format-features{
    width: 100%;
    margin-bottom: 1.5rem;
  }

  #purchase .book-format-card .buy-options{
    width: 100%;
  }
}




