/* WhereTooEat :8765 - transparent bottom chapters + fire-steak footer video + smoke.
   Loaded after auditfix-8765.css. Pairs with js/footer-fire-8765.js.
   Scope: #discFeatured + #discNewest (the 2 sections above the footer), #siteFooter
   (whole footer + its last 3 columns Owners / Company / Follow Us + bottom strip).
   Cards, pills and CTAs keep their own backgrounds. */

/* ---------- 1. Featured + Newest wrappers: no background, no overlay, no seam wash ---------- */
#discoveryStack #discFeatured,
#discoveryStack #discNewest {
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border-top: 0 !important;
  border-bottom: 0 !important;
}
#discoveryStack #discFeatured::before,
#discoveryStack #discFeatured::after,
#discoveryStack #discNewest::before,
#discoveryStack #discNewest::after {
  content: none !important;
  background: none !important;
}
#discFeatured > .disc-inner, #discFeatured .disc-head, #discFeatured .disc-carousel,
#discNewest > .disc-inner, #discNewest .disc-head, #discNewest .disc-carousel {
  background: none !important;
  box-shadow: none !important;
}

/* ---------- 2. Footer: transparent block + last 3 columns + bottom strip ---------- */
#siteFooter.site-footer {
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border-top: 0 !important;
  position: relative;
  z-index: 2;
  isolation: isolate;
  overflow: visible;
}
#siteFooter .site-footer-inner,
#siteFooter .site-footer-inner > div:nth-last-child(-n+3),
#siteFooter .site-footer-bottom {
  background: none !important;
  box-shadow: none !important;
}
#siteFooter .site-footer-inner,
#siteFooter .site-footer-bottom { position: relative; z-index: 1; }
/* readability over video */
#siteFooter h5, #siteFooter h2, #siteFooter a, #siteFooter p, #siteFooter .site-footer-bottom {
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.95), 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 10px rgba(0, 0, 0, 0.75), 0 0 22px rgba(0, 0, 0, 0.5); /* FOOTER-NO-OVERLAY: text-only halo, no area dimming */
}
#discNewest .disc-head h2, #discNewest .disc-head h3 {
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.95), 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 10px rgba(0, 0, 0, 0.75), 0 0 22px rgba(0, 0, 0, 0.5); /* FOOTER-NO-OVERLAY: heading sits on the bare video */
}
/* FOOTER-NO-OVERLAY: cards on the fire video keep border/background but lose the 0 12px 32px rgba(0,0,0,.42)
   drop-shadow that darkened the video around them (inset highlight kept). */
#discNewest .premium-card, #discNewest .disc-card { box-shadow: var(--wte-glass-hi, none); }
#siteFooter .site-footer-bottom { color: #b3c4ce; }
#siteFooter .site-footer-tag { color: #c3d2da; }

/* ---------- 3. Page-level stack background stops before Newest (so the fire shows through) ----------
   The stack's own gradient moves to ::before (same gradient) and fades out over the
   Featured->Newest boundary, so there is no hard seam. */
#discoveryStack.wte-fire-ready { background: none !important; }
#discoveryStack.wte-fire-ready::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  /* reviewfix P2-6: background comes from uifix-8765.css section 3 (single owner) */
  -webkit-mask-image: linear-gradient(180deg, #000 0, #000 calc(100% - var(--wte-fire-reach, 0px) - 40px), transparent calc(100% - var(--wte-fire-reach, 0px)));
          mask-image: linear-gradient(180deg, #000 0, #000 calc(100% - var(--wte-fire-reach, 0px) - 40px), transparent calc(100% - var(--wte-fire-reach, 0px)));
}

/* ---------- 4. One continuous fire layer: Newest (reach) + footer ---------- */
.wte-fire-layer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: calc(-1 * var(--wte-fire-reach, 0px));
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background: #07141c;
  contain: strict;
}
.wte-fire-layer .wte-fire-poster,
.wte-fire-layer .wte-fire-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 100%;
  display: block;
}
.wte-fire-layer .wte-fire-poster { background-size: cover; background-position: 50% 100%; background-repeat: no-repeat; opacity: 0; transition: opacity .6s ease; }
.wte-fire-layer.has-poster .wte-fire-poster { opacity: 1; }
.wte-fire-layer .wte-fire-video { opacity: 0; transition: opacity .9s ease; }
.wte-fire-layer.is-playing .wte-fire-video { opacity: 1; }
/* contrast shades live on the video layer (not on the sections) */
/* FOOTER-NO-OVERLAY 2026-10-06: Daniel wants the fire video at full colour/resolution with nothing over it.
   The two shades below (top 100%->34% navy fade over the Newest section, foot 50-84% navy over the footer) are off. */
.wte-fire-shade { display: none !important; }
.wte-fire-shade--top {
  top: 0;
  height: var(--wte-fire-reach, 0px);
  background: linear-gradient(180deg,
    #07141c 0%, rgba(7, 20, 28, 0.92) 16%, rgba(7, 20, 28, 0.62) 42%,
    rgba(7, 20, 28, 0.34) 78%, rgba(5, 12, 18, 0.5) 100%);
}
.wte-fire-shade--foot {
  top: var(--wte-fire-reach, 0px);
  bottom: 0;
  background: linear-gradient(180deg,
    rgba(5, 12, 18, 0.5) 0%, rgba(4, 10, 14, 0.8) 70px, rgba(4, 10, 14, 0.84) 100%);
}

/* ---------- 5. Smoke rising from the fire into Featured (over the cards, click-through) ---------- */
.wte-smoke {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 4;
  pointer-events: none;
  overflow: hidden;
  contain: layout paint;
  -webkit-mask-image: linear-gradient(0deg, transparent 0, transparent var(--wte-fire-reach, 0px), #000 calc(var(--wte-fire-reach, 0px) + 90px), #000 85%, transparent 100%);
          mask-image: linear-gradient(0deg, transparent 0, transparent var(--wte-fire-reach, 0px), #000 calc(var(--wte-fire-reach, 0px) + 90px), #000 85%, transparent 100%);
}
.wte-smoke span {
  position: absolute;
  bottom: -12%;
  left: var(--x, 50%);
  width: var(--s, 420px);
  height: var(--s, 420px);
  margin-left: calc(var(--s, 420px) / -2);
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(226, 230, 236, 0.16), rgba(210, 216, 224, 0.07) 55%, transparent 100%);
  opacity: 0;
  will-change: transform, opacity;
  animation: wteSmokeRise var(--d, 18s) linear var(--delay, 0s) infinite;
  animation-play-state: paused;
}
.wte-smoke.is-active span { animation-play-state: running; }
@keyframes wteSmokeRise {
  0%   { transform: translate3d(0, 0, 0) scale(0.55); opacity: 0; }
  15%  { opacity: 0.85; }
  60%  { opacity: 0.55; }
  100% { transform: translate3d(var(--dx, 40px), calc(-1 * var(--rise, 900px)), 0) scale(1.5); opacity: 0; }
}

/* ---------- 6. Lite: reduced motion / Save-Data => poster only, no smoke ---------- */
html.wte-fire-lite .wte-smoke { display: none !important; }
html.wte-fire-lite .wte-fire-video { display: none !important; }
@media (prefers-reduced-motion: reduce) {
  .wte-smoke { display: none !important; }
  .wte-fire-video { display: none !important; }
}
@media (max-width: 720px) {
  .wte-smoke span { width: calc(var(--s, 420px) * 0.62); height: calc(var(--s, 420px) * 0.62); margin-left: calc(var(--s, 420px) * -0.31); }
  .wte-fire-shade--foot {
    background: linear-gradient(180deg, rgba(5, 12, 18, 0.55) 0%, rgba(4, 10, 14, 0.84) 60px, rgba(4, 10, 14, 0.86) 100%);
  }
}
