/* ==========================================================
   26. SITE FOOTER
   Explore Natural Tunnel
   ========================================================== */


/* ----------------------------------------------------------
   FOOTER SHELL
   Full-bleed background
   ---------------------------------------------------------- */

.ent-footer {
  position: relative;
  width: 100%;
  max-width: none !important;

  margin: 0 !important;
  padding: 0 !important;

  background: var(--ent-forest-dark);
  color: var(--ent-white);

  overflow: hidden;
}


/* Remove inherited WordPress block spacing */

.ent-footer,
.ent-footer > *,
.ent-footer-inner,
.ent-footer-main,
.ent-footer-bottom {
  margin-block-start: 0 !important;
  margin-block-end: 0 !important;
}


/* ----------------------------------------------------------
   INNER CONTAINER
   Controls the actual footer content width
   ---------------------------------------------------------- */

.ent-footer-inner {
  position: relative;
  z-index: 1;

  width: min(
    calc(100% - (var(--ent-gutter) * 2)),
    var(--ent-container-wide)
  );

  max-width: var(--ent-container-wide) !important;

  margin-inline: auto !important;

  padding: 88px 0 34px !important;
}


/* ----------------------------------------------------------
   MAIN FOOTER LAYOUT
   Logo | Navigation | Social | Statement
   ---------------------------------------------------------- */

.ent-footer-main {
  display: grid !important;

  grid-template-columns:
    minmax(250px, 1.2fr)
    minmax(360px, 1.65fr)
    minmax(90px, 0.35fr)
    minmax(270px, 1fr);

  column-gap: clamp(40px, 4vw, 76px);
  row-gap: 40px;

  width: 100% !important;
  max-width: none !important;

  align-items: start !important;
  justify-content: stretch !important;

  margin: 0 !important;
  padding: 0 !important;
}


/* Make sure WordPress Row behavior cannot collapse children */

.ent-footer-main > * {
  min-width: 0;
  margin: 0 !important;
}


/* ----------------------------------------------------------
   BRAND / MOBILE LOGO IMAGE
   ---------------------------------------------------------- */

.ent-footer-brand {
  display: block !important;

  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
}


/* Supports the Image block currently inside ent-footer-brand */

.ent-footer-brand .wp-block-image {
  display: block;

  margin: 0 !important;
  padding: 0 !important;
}

.ent-footer-brand .wp-block-image img {
  display: block;

  width: 100%;
  max-width: 310px;
  height: auto;

  object-fit: contain;
  object-position: left top;
}


/* Fallback if the block is ever changed back to Site Logo */

.ent-footer-brand .wp-block-site-logo {
  margin: 0 !important;
}

.ent-footer-brand .wp-block-site-logo img {
  display: block;

  width: 100%;
  max-width: 310px;
  height: auto;
}


/* ----------------------------------------------------------
   NAVIGATION
   ---------------------------------------------------------- */

.ent-footer-nav {
  display: block !important;

  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
}


/* Footer never needs the hamburger */

.ent-footer-nav .wp-block-navigation__responsive-container-open {
  display: none !important;
}


/* Keep actual navigation visible */

.ent-footer-nav .wp-block-navigation__responsive-container {
  position: static !important;

  display: block !important;

  width: 100% !important;

  background: transparent !important;
  color: inherit !important;
}


/* Remove overlay mechanics inherited from Navigation block */

.ent-footer-nav .wp-block-navigation__responsive-container-content {
  display: block !important;

  padding: 0 !important;
}


/* Two-column footer menu */

.ent-footer-nav .wp-block-navigation__container {
  display: grid !important;

  grid-template-columns: repeat(2, minmax(140px, 1fr));

  gap: 18px 42px !important;

  width: 100%;

  align-items: start !important;
  justify-items: start !important;

  margin: 0 !important;
  padding: 0 !important;
}


.ent-footer-nav .wp-block-navigation-item {
  display: block !important;

  width: auto;

  margin: 0 !important;
  padding: 0 !important;
}


.ent-footer-nav .wp-block-navigation-item__content {
  display: inline-block;

  padding: 0 !important;

  font-family: var(--ent-font-body);
  font-size: 15px;
  font-weight: var(--ent-weight-regular);

  line-height: 1.45;

  color: rgba(255, 255, 255, 0.82) !important;

  text-decoration: none;

  transition:
    color var(--ent-speed-fast) ease,
    transform var(--ent-speed-fast) ease;
}


.ent-footer-nav .wp-block-navigation-item__content:hover,
.ent-footer-nav .wp-block-navigation-item__content:focus-visible {
  color: var(--ent-white) !important;
}


/* Explore → */

.ent-footer-nav
.wp-block-navigation__container
> .wp-block-navigation-item:last-child
> .wp-block-navigation-item__content {
  color: var(--ent-rust-light) !important;
  font-weight: var(--ent-weight-semibold);
}


/* ----------------------------------------------------------
   SOCIAL ICONS
   ---------------------------------------------------------- */

.ent-footer-social {
  display: flex !important;

  flex-direction: row !important;
  flex-wrap: nowrap !important;

  align-items: center !important;
  justify-content: flex-start !important;

  gap: 20px !important;

  width: auto;

  margin: 0 !important;
  padding: 1px 0 0 !important;

  list-style: none !important;
}


.ent-footer-social .wp-social-link {
  display: block !important;

  margin: 0 !important;
  padding: 0 !important;

  background: transparent !important;
  color: var(--ent-white) !important;

  transition:
    transform var(--ent-speed-fast) ease,
    opacity var(--ent-speed-fast) ease;
}


.ent-footer-social .wp-social-link a {
  display: flex !important;

  align-items: center;
  justify-content: center;

  padding: 0 !important;

  color: var(--ent-white) !important;
}


.ent-footer-social svg {
  display: block;

  width: 24px !important;
  height: 24px !important;

  fill: currentColor;
}


.ent-footer-social .wp-social-link:hover {
  opacity: 0.72;
  transform: translateY(-2px);
}


/* ----------------------------------------------------------
   BRAND STATEMENT
   ---------------------------------------------------------- */

.ent-footer-message {
  position: relative;

  display: block !important;

  width: 100%;
  min-width: 0;

  margin: 0 !important;

  padding: 2px 0 4px 30px !important;

  border-left: 1px solid rgba(255, 255, 255, 0.30);
}


.ent-footer-message p {
  display: block !important;

  margin: 0 !important;
  padding: 0 !important;

  font-family: var(--ent-font-display);

  font-size: clamp(1.55rem, 1.8vw, 2.05rem);
  font-weight: var(--ent-weight-regular);

  line-height: 1.08;
  letter-spacing: var(--ent-tracking-tight);

  color: var(--ent-cream) !important;
}


/* First line */

.ent-footer-message p:first-child {
  font-style: italic;
}


/* Second line */

.ent-footer-message p + p {
  margin-top: 8px !important;
}


/* Rust accent */

.ent-footer-message::after {
  content: "";

  display: block;

  width: 48px;
  height: 3px;

  margin-top: 22px;

  background: var(--ent-rust);
}


/* ----------------------------------------------------------
   COPYRIGHT / LEGAL ROW
   ---------------------------------------------------------- */

.ent-footer-bottom {
  display: flex !important;

  flex-direction: row !important;

  align-items: center !important;
  justify-content: space-between !important;

  width: 100% !important;

  gap: 32px;

  margin: 72px 0 0 !important;
  padding: 26px 0 0 !important;

  border-top: 1px solid rgba(255, 255, 255, 0.20);
}


/* Make both Gutenberg paragraphs visible */

.ent-footer-bottom > p,
.ent-footer-bottom .wp-block-paragraph {
  display: block !important;

  margin: 0 !important;
  padding: 0 !important;

  font-family: var(--ent-font-body);

  font-size: 12px;
  font-weight: var(--ent-weight-regular);

  line-height: 1.5;
  letter-spacing: 0.04em;

  color: rgba(255, 255, 255, 0.56) !important;
}


.ent-footer-bottom a {
  color: rgba(255, 255, 255, 0.68) !important;

  text-decoration: none;

  transition: color var(--ent-speed-fast) ease;
}


.ent-footer-bottom a:hover,
.ent-footer-bottom a:focus-visible {
  color: var(--ent-white) !important;
}


/* ==========================================================
   FOOTER — TABLET
   ========================================================== */

@media (max-width: 1180px) {

  .ent-footer-inner {
    padding-top: 76px !important;
  }


  .ent-footer-main {
    grid-template-columns:
      minmax(220px, 1fr)
      minmax(320px, 1.45fr)
      auto;

    column-gap: 48px;
  }


  /* Statement becomes full-width second row */

  .ent-footer-message {
    grid-column: 1 / -1;

    max-width: 520px;

    margin-top: 18px !important;
  }

}


/* ==========================================================
   FOOTER — MOBILE
   ========================================================== */

@media (max-width: 782px) {

  .ent-footer-inner {
    width: calc(100% - 48px);

    padding-top: 60px !important;
    padding-bottom: 28px !important;
  }


  .ent-footer-main {
    display: flex !important;

    flex-direction: column !important;

    align-items: flex-start !important;

    gap: 0 !important;
  }


  /* Logo */

  .ent-footer-brand {
    margin-bottom: 46px !important;
  }


  .ent-footer-brand .wp-block-image img,
  .ent-footer-brand .wp-block-site-logo img {
    max-width: 260px;
  }


  /* Navigation */

  .ent-footer-nav {
    width: 100%;

    margin-bottom: 44px !important;
  }


  .ent-footer-nav .wp-block-navigation__container {
    display: grid !important;

    grid-template-columns: 1fr;

    gap: 14px !important;
  }


  .ent-footer-nav .wp-block-navigation-item__content {
    font-size: 15px;
  }


  /* Social */

  .ent-footer-social {
    margin-bottom: 46px !important;

    gap: 22px !important;
  }


  .ent-footer-social svg {
    width: 25px !important;
    height: 25px !important;
  }


  /* Statement */

  .ent-footer-message {
    width: 100%;

    max-width: 430px;

    margin: 0 !important;

    padding-left: 22px !important;
  }


  .ent-footer-message p {
    font-size: clamp(1.65rem, 7vw, 2rem);
  }


  /* Legal */

  .ent-footer-bottom {
    flex-direction: column !important;

    align-items: flex-start !important;
    justify-content: flex-start !important;

    gap: 8px;

    margin-top: 54px !important;
    padding-top: 24px !important;
  }

}


/* ==========================================================
   FOOTER — SMALL MOBILE
   ========================================================== */

@media (max-width: 480px) {

  .ent-footer-inner {
    width: calc(100% - 36px);
  }


  .ent-footer-brand .wp-block-image img,
  .ent-footer-brand .wp-block-site-logo img {
    max-width: 235px;
  }


  .ent-footer-message {
    padding-left: 18px !important;
  }


  .ent-footer-bottom > p,
  .ent-footer-bottom .wp-block-paragraph {
    font-size: 11px;
  }

}



/* ----------------------------------------------------------
   FORCE FOOTER FULL-BLEED TO VIEWPORT
   ---------------------------------------------------------- */

.ent-footer {
  width: 100vw !important;
  max-width: 100vw !important;

  margin-left: calc(50% - 50vw) !important;
  margin-right: calc(50% - 50vw) !important;
  margin-bottom: 0 !important;

  border-radius: 0 !important;
}

/* Remove theme spacing surrounding the Footer template part */

footer.wp-block-template-part,
.wp-block-template-part:has(.ent-footer) {
  margin: 0 !important;
  padding: 0 !important;
}

/* Remove Twenty Twenty-Five block-gap below the footer */

body > .wp-site-blocks {
  padding-bottom: 0 !important;
}

.wp-site-blocks > footer:last-child,
.wp-site-blocks > .wp-block-template-part:last-child {
  margin-bottom: 0 !important;
}


/* ==========================================================
   FOOTER — REMOVE THEME / TEMPLATE BOTTOM SPACE
   ========================================================== */

/* Footer template part itself */
footer.wp-block-template-part,
.wp-block-template-part:has(.ent-footer) {
  margin: 0 !important;
  padding: 0 !important;
  background: var(--ent-forest-dark) !important;
}

/* Outer wrapper WordPress places around our footer */
.wp-block-template-part:has(.ent-footer) > * {
  margin-bottom: 0 !important;
}

/* Our outer footer block */
.ent-footer {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

/* Prevent inherited block gap after footer content */
.ent-footer > :last-child,
.ent-footer-inner > :last-child {
  margin-bottom: 0 !important;
}

/* Remove bottom padding from the site canvas */
.wp-site-blocks {
  padding-bottom: 0 !important;
}

/* If the footer is the final block, it ends at the viewport */
.wp-site-blocks > :last-child {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

/* Footer should never inherit the site's rounded canvas */
footer.wp-block-template-part,
.wp-block-template-part:has(.ent-footer),
.wp-site-blocks:has(.ent-footer) {
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}




