/* TSEA Site Experience v1.0.9
   Conservative Avenue shell cleanup.
   IMPORTANT: this file changes the legacy page shell, not the internal layout
   of old page content or purpose-built TSEA applications. */

body.tsea-fullwidth-layout:not(.tsea-layout-protected) #secondary,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) #sidebar,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) .sidebar,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) .sidebar-right,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) .right-sidebar,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) aside.sidebar,
body.tsea-fullwidth-layout:not(.tsea-layout-protected) aside.widget-area {
  display:none !important;
}

/* Release ONLY the Avenue branch that formerly sat beside the sidebar.
   Never mark/resize .entry-content, .post-entry, or descendants themselves. */
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch {
  box-sizing:border-box !important;
  float:none !important;
  clear:both !important;
  left:auto !important;
  right:auto !important;
  width:100% !important;
  max-width:none !important;
}

body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
  box-sizing:border-box !important;
  width:100% !important;
  max-width:1180px !important;
  margin-left:auto !important;
  margin-right:auto !important;
}

/* Keep legacy page internals at their natural width. The Avenue content branch
   already owns the reclaimed sidebar space; do not impose a second reading-width
   constraint here. This preserves the v1.0.7 layout behavior that tested correctly. */

/* Safe media rule only; no forced widths and no float changes. */
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content img,
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content img,
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content video,
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content video {
  max-width:100%;
  height:auto;
}

@media screen and (max-width:900px) {
  html, body.tsea-fullwidth-layout { width:100% !important; min-width:0 !important; overflow-x:hidden !important; }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
    width:100% !important;
    min-width:0 !important;
    max-width:none !important;
  }
}

/* v1.0.10 — centered legacy content framework.
   Keep the v1.0.7/v1.0.9 Avenue branch fix; simply inset that framework evenly
   so legacy text cannot run against or beyond either edge. */
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
  padding-left:24px !important;
  padding-right:24px !important;
}
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch,
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch .entry-content,
body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch .page-content {
  box-sizing:border-box !important;
  max-width:100% !important;
}
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
    padding-left:18px !important;
    padding-right:18px !important;
  }
}

/* v1.0.11 — Avenue mobile containment.
   Restore the proven fix for Avenue's desktop-width canvas on phones.
   Desktop rules above are intentionally unchanged. */
@media screen and (max-width:900px) {
  html,
  body.tsea-fullwidth-layout {
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    overflow-x:hidden !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #wrapper,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #page,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .site,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #primary,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .content-area,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .site-main,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #wrapper-content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #fullwidth,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch {
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    margin-left:0 !important;
    margin-right:0 !important;
    float:none !important;
    box-sizing:border-box !important;
  }

  /* The framework owns the phone gutters. */
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
    padding-left:18px !important;
    padding-right:18px !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .post-entry,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) article {
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
    overflow-wrap:anywhere;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content img,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content img,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content iframe,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content iframe,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .entry-content video,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .page-content video {
    max-width:100% !important;
    height:auto;
  }
}


/* v1.0.12 — final mobile gutters + duplicate Avenue desktop nav suppression.
   Keep the v1.0.11 shrink-to-phone fix intact. Put the gutter on the actual
   content branch so headings, media and body copy share one framework. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
    padding-left:0 !important;
    padding-right:0 !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch {
    padding-left:22px !important;
    padding-right:22px !important;
    box-sizing:border-box !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch .entry-content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch .page-content,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch .post-entry {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  /* Avenue's desktop navigation must not render underneath the mobile-menu
     header. The mobile hamburger remains the only navigation control. */
  body.tsea-fullwidth-layout #navigation {
    display:none !important;
  }
}


/* v1.0.13 — mobile breathing room + remove Avenue's stray fixed logo text.
   Do not alter the working shrink-to-phone/layout rules above. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch {
    padding-left:30px !important;
    padding-right:30px !important;
  }

  /* Avenue can leave its text/pseudo logo layered over the mobile logo.
     Keep the real image, suppress only generated/text logo content. */
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo a {
    font-size:0 !important;
    text-indent:0 !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo::before,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo::after,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo a::before,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo a::after {
    content:none !important;
    display:none !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #logo img {
    font-size:initial !important;
  }
}

/* v1.0.14 — desktop framework breathing room + legacy Avenue footer stacking.
   Do not alter the working mobile body/content rules from v1.0.13. */
@media screen and (min-width:901px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-sidebar-row {
    padding-left:36px !important;
    padding-right:36px !important;
  }
}

@media screen and (max-width:900px) {
  /* Avenue's footer widgets were built as desktop columns. Stack only footer
     columns/widgets on phones; do not touch page content or application UIs. */
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer-wrap,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer-wrapper,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .footer,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-footer {
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer .widget,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer .footer-widget,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer [class*="one-third"],
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer [class*="one_half"],
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer [class*="one-half"],
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer [class*="column"],
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-footer .widget,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-footer [class*="column"] {
    display:block !important;
    float:none !important;
    clear:both !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    margin-left:0 !important;
    margin-right:0 !important;
    box-sizing:border-box !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer .widget + .widget,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer .footer-widget + .footer-widget,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-footer .widget + .widget {
    margin-top:28px !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #footer img,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-footer img {
    max-width:100% !important;
    height:auto !important;
  }
}

/* v1.0.15 — exact sitewide mobile footer + stray TSEA mark fix.
   Elements are tagged by legacy-layout.js from the rendered Avenue DOM. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-rogue-theme-mark {
    display:none !important;
    visibility:hidden !important;
    opacity:0 !important;
    pointer-events:none !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-legacy-footer-widgets {
    display:block !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    height:auto !important;
    overflow:hidden !important;
    box-sizing:border-box !important;
    padding-left:30px !important;
    padding-right:30px !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-legacy-footer-widget {
    display:block !important;
    float:none !important;
    clear:both !important;
    position:static !important;
    left:auto !important;
    right:auto !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    height:auto !important;
    margin:0 0 30px 0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
    transform:none !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-legacy-footer-widget:last-child {
    margin-bottom:0 !important;
  }
}


/* v1.0.16 — modern legacy footer, desktop + mobile. */
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-rogue-theme-mark {
  display:none !important;
  visibility:hidden !important;
  opacity:0 !important;
  pointer-events:none !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer {
  display:block !important;
  float:none !important;
  clear:both !important;
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  height:auto !important;
  margin:48px 0 0 !important;
  padding:42px max(36px, calc((100% - 1180px)/2 + 36px)) 38px !important;
  box-sizing:border-box !important;
  overflow:hidden !important;
  background:#1c2a58 !important;
  color:#fff !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about {
  display:block !important;
  float:none !important;
  position:static !important;
  width:100% !important;
  max-width:1180px !important;
  min-width:0 !important;
  margin:0 auto !important;
  padding:0 !important;
  box-sizing:border-box !important;
  color:#fff !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h1,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h3,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h4 {
  color:#fff !important;
  font-family:inherit !important;
  font-style:normal !important;
  font-size:24px !important;
  line-height:1.2 !important;
  margin:0 0 12px !important;
  padding:0 !important;
  border:0 !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
  color:rgba(255,255,255,.88) !important;
  font-size:16px !important;
  line-height:1.65 !important;
  max-width:820px !important;
  margin:0 !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
  display:flex !important;
  flex-wrap:wrap !important;
  gap:10px 22px !important;
  margin-top:24px !important;
  padding-top:20px !important;
  border-top:1px solid rgba(255,255,255,.18) !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a {
  color:#fff !important;
  text-decoration:none !important;
  font-weight:600 !important;
  font-size:15px !important;
  line-height:1.4 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a:hover,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a:focus {
  text-decoration:underline !important;
}

body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-copyright {
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  margin:0 !important;
  padding:18px 36px !important;
  box-sizing:border-box !important;
  text-align:center !important;
  color:#566074 !important;
  font-size:14px !important;
  line-height:1.4 !important;
}

@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer {
    margin-top:36px !important;
    padding:32px 30px 28px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h1,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h3,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h4 {
    font-size:22px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
    font-size:15px !important;
    line-height:1.6 !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:14px 20px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-copyright {
    padding:16px 30px !important;
    font-size:13px !important;
  }
}


/* v1.0.18 — quiet, clean legacy footer. No chunky color block. */
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer {
  display:block !important;
  width:100% !important;
  max-width:none !important;
  min-width:0 !important;
  height:auto !important;
  margin:42px 0 0 !important;
  padding:28px max(36px, calc((100% - 1180px)/2 + 36px)) 18px !important;
  box-sizing:border-box !important;
  overflow:visible !important;
  background:#fff !important;
  color:#1c2a58 !important;
  border-top:1px solid #e2e5ea !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about {
  display:block !important;
  width:100% !important;
  max-width:1180px !important;
  margin:0 auto !important;
  padding:0 !important;
  color:#1c2a58 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h1,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h3,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h4 {
  color:#1c2a58 !important;
  font-family:inherit !important;
  font-style:normal !important;
  font-size:20px !important;
  line-height:1.25 !important;
  margin:0 0 8px !important;
  padding:0 !important;
  border:0 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
  color:#566074 !important;
  font-size:15px !important;
  line-height:1.55 !important;
  max-width:900px !important;
  margin:0 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
  display:flex !important;
  flex-direction:row !important;
  flex-wrap:wrap !important;
  align-items:center !important;
  gap:8px 24px !important;
  max-width:1180px !important;
  margin:18px auto 0 !important;
  padding:16px 0 0 !important;
  border-top:1px solid #e2e5ea !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links h3 { display:none !important; }
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a {
  color:#1c2a58 !important;
  text-decoration:none !important;
  font-weight:600 !important;
  font-size:14px !important;
  line-height:1.4 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a:hover,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a:focus-visible {
  color:#ec1e2f !important;
  text-decoration:underline !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-game-umbrella {
  display:block !important;
  appearance:none !important;
  -webkit-appearance:none !important;
  float:right !important;
  width:auto !important;
  height:auto !important;
  margin:12px 0 0 !important;
  padding:0 !important;
  border:0 !important;
  outline-offset:3px !important;
  background:transparent !important;
  box-shadow:none !important;
  color:#b8bec8 !important;
  font-size:16px !important;
  line-height:1 !important;
  cursor:pointer !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-game-umbrella:hover,
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-game-umbrella:focus-visible { color:#8d96a5 !important; }
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-copyright {
  display:block !important;
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  margin:0 !important;
  padding:14px 36px 18px !important;
  box-sizing:border-box !important;
  text-align:left !important;
  color:#8a92a0 !important;
  background:#fff !important;
  font-size:13px !important;
  line-height:1.4 !important;
  border:0 !important;
}
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer {
    margin-top:32px !important;
    padding:24px 30px 14px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h1,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h3,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h4 { font-size:19px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
    font-size:14px !important;
    line-height:1.55 !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
    display:flex !important;
    flex-direction:row !important;
    flex-wrap:wrap !important;
    gap:10px 18px !important;
    margin-top:16px !important;
    padding-top:14px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a { font-size:13px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-game-umbrella {
    float:right !important;
    margin-top:12px !important;
    font-size:15px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-copyright {
    padding:12px 30px 16px !important;
    font-size:12px !important;
  }
}


/* v1.0.19 — controlled clean footer; intentionally independent of Avenue widget columns. */
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer {
  clear:both !important; float:none !important; position:relative !important;
  display:block !important; width:100% !important; max-width:none !important;
  height:auto !important; min-height:0 !important; margin:38px 0 0 !important;
  padding:0 !important; background:#fff !important; border-top:1px solid #e3e6eb !important;
  overflow:visible !important; box-sizing:border-box !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-inner {
  display:block !important; float:none !important; position:static !important;
  width:100% !important; max-width:1180px !important; height:auto !important;
  margin:0 auto !important; padding:26px 36px 16px !important; box-sizing:border-box !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about {
  display:block !important; float:none !important; position:static !important;
  width:100% !important; max-width:none !important; height:auto !important; margin:0 !important; padding:0 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2 {
  margin:0 0 8px !important; padding:0 !important; border:0 !important;
  color:#1c2a58 !important; font-family:inherit !important; font-style:normal !important;
  font-size:19px !important; line-height:1.3 !important; font-weight:600 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
  width:100% !important; max-width:1000px !important; margin:0 !important; padding:0 !important;
  color:#566074 !important; font-size:14px !important; line-height:1.55 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
  clear:both !important; float:none !important; position:static !important;
  display:flex !important; flex-direction:row !important; flex-wrap:wrap !important; align-items:center !important;
  width:100% !important; max-width:none !important; height:auto !important;
  margin:18px 0 0 !important; padding:14px 0 !important; gap:8px 24px !important;
  border-top:1px solid #e3e6eb !important; border-bottom:1px solid #e3e6eb !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a {
  display:inline-block !important; float:none !important; position:static !important;
  width:auto !important; margin:0 !important; padding:0 !important;
  color:#1c2a58 !important; font-size:13px !important; line-height:1.4 !important; font-weight:600 !important;
  text-decoration:none !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom {
  clear:both !important; float:none !important; position:static !important;
  display:flex !important; align-items:center !important; justify-content:space-between !important;
  width:100% !important; height:auto !important; margin:0 !important; padding:12px 0 0 !important;
  color:#8a92a0 !important; font-size:12px !important; line-height:1.4 !important;
}
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom .tsea-game-umbrella {
  display:inline-block !important; float:none !important; position:static !important;
  width:auto !important; height:auto !important; min-width:0 !important; min-height:0 !important;
  margin:0 !important; padding:0 !important; border:0 !important; border-radius:0 !important;
  background:transparent !important; box-shadow:none !important; color:#c0c5cd !important;
  font-size:15px !important; line-height:1 !important; cursor:pointer !important;
}
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer { margin-top:30px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-inner { padding:22px 30px 14px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about h2 { font-size:18px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p { font-size:13px !important; line-height:1.55 !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links { gap:9px 18px !important; margin-top:16px !important; padding:12px 0 !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a { font-size:12px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom { font-size:11px !important; padding-top:11px !important; }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom .tsea-game-umbrella { font-size:14px !important; }
}


/* v1.0.20 — mobile-only footer containment. Desktop v1.0.19 remains untouched. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-inner,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom {
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-inner {
    overflow:hidden !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-about p {
    white-space:normal !important;
    overflow-wrap:anywhere !important;
    word-break:normal !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) minmax(0,1fr) !important;
    column-gap:18px !important;
    row-gap:10px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-footer-links a {
    display:block !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    white-space:normal !important;
    overflow-wrap:anywhere !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom > * {
    min-width:0 !important;
  }
}


/* v1.0.21 — mobile footer is viewport-owned, not Avenue-column-owned. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) > .tsea-modern-legacy-footer {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin-left:0 !important;
    margin-right:0 !important;
    overflow:hidden !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) > .tsea-modern-legacy-footer .tsea-footer-clean-inner {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    padding-left:30px !important;
    padding-right:30px !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) > .tsea-modern-legacy-footer .tsea-modern-footer-about,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) > .tsea-modern-legacy-footer .tsea-modern-footer-about p {
    width:auto !important;
    max-width:none !important;
    min-width:0 !important;
    white-space:normal !important;
    overflow-wrap:break-word !important;
  }
}

/* v1.0.23 — keep the original game umbrella in the footer flow, never viewport-fixed. */
body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-footer-clean-bottom .tsea-footer-original-umbrella {
  position:static !important;
  inset:auto !important;
  top:auto !important;
  right:auto !important;
  bottom:auto !important;
  left:auto !important;
  transform:none !important;
  float:none !important;
  display:inline-block !important;
  width:auto !important;
  height:auto !important;
  min-width:0 !important;
  min-height:0 !important;
  margin:0 0 0 auto !important;
  padding:0 !important;
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
  color:#c0c5cd !important;
  font-size:15px !important;
  line-height:1 !important;
  opacity:1 !important;
  z-index:auto !important;
}


/* v1.0.25 — restore and standardize Avenue's EXISTING mobile header on normal pages.
   Do not substitute a separate Mobile Menu header. Keep desktop and protected app pages untouched. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #header {
    display:block !important;
    min-height:92px !important;
    height:92px !important;
    position:relative !important;
    width:100% !important;
    box-sizing:border-box !important;
    overflow:visible !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo {
    display:block !important;
    float:none !important;
    position:absolute !important;
    left:50% !important;
    top:50% !important;
    transform:translate(-50%,-50%) !important;
    width:240px !important;
    max-width:calc(100% - 150px) !important;
    height:auto !important;
    margin:0 !important;
    padding:0 !important;
    z-index:2 !important;
    font-size:0 !important;
    line-height:0 !important;
    text-indent:0 !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo a {
    display:block !important;
    width:100% !important;
    height:auto !important;
    margin:0 !important;
    padding:0 !important;
    font-size:0 !important;
    line-height:0 !important;
    text-indent:0 !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo img {
    display:block !important;
    width:240px !important;
    max-width:100% !important;
    max-height:72px !important;
    height:auto !important;
    margin:0 auto !important;
    object-fit:contain !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo::before,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo::after,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo a::before,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #logo a::after {
    content:none !important;
    display:none !important;
  }

  /* Do not render the Mobile Menu plugin's separate header shell on interior pages;
     its hamburger control remains available independently, as it did before v1.0.24. */
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-header-holder {
    background:transparent !important;
    height:0 !important;
    min-height:0 !important;
    margin:0 !important;
    padding:0 !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-logo-holder {
    display:none !important;
  }
}


/* v1.0.26 — mobile interior header behavior only.
   Keep the v1.0.25 appearance; pin that existing Avenue header like the homepage header. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) {
    padding-top:92px !important;
  }

  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #header {
    position:fixed !important;
    top:0 !important;
    right:0 !important;
    bottom:auto !important;
    left:0 !important;
    width:100% !important;
    height:92px !important;
    min-height:92px !important;
    margin:0 !important;
    z-index:99990 !important;
    background:#fff !important;
  }
}


/* v1.0.27 — final mobile interior header correction.
   Use the same proven Mobile Menu header shell as the homepage so the hamburger
   and centered TSEA logo are one fixed unit. Desktop/protected apps unchanged. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) { padding-top:78px !important; }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) #header { display:none !important; }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-header-holder {
    background:#fff !important; display:block !important; visibility:visible !important;
    position:fixed !important; top:0 !important; right:0 !important; bottom:auto !important; left:0 !important;
    width:100% !important; height:78px !important; min-height:78px !important;
    margin:0 !important; padding:0 !important; overflow:visible !important; z-index:99999 !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-logo-holder {
    background:transparent !important; display:block !important; visibility:visible !important;
    position:absolute !important; top:0 !important; left:50% !important;
    width:240px !important; max-width:calc(100% - 150px) !important; height:78px !important;
    margin:0 !important; padding:0 !important; overflow:hidden !important;
    transform:translateX(-50%) !important; font-size:0 !important; line-height:0 !important; z-index:2 !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-logo-holder > * { display:none !important; visibility:hidden !important; }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-logo-holder::before {
    content:"" !important; display:block !important; width:240px !important; max-width:100% !important;
    height:68px !important; margin:5px auto !important;
    background:url("https://tseaonline.org/wp-content/uploads/2019-Banner-Logo.png") center / contain no-repeat !important;
  }
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mobmenul-container,
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mobmenu-left-bt {
    display:block !important; visibility:visible !important; position:absolute !important;
    left:14px !important; top:15px !important; z-index:5 !important;
  }
}


/* v1.0.28 — Member Portal mobile containment only.
   The legacy portal templates contain desktop-width descendants. Keep the now-working
   global header/footer untouched and constrain only portal page content on phones. */
@media screen and (max-width:900px) {
  body.tsea-member-portal-page:not(.tsea-layout-protected) {
    overflow-x:hidden !important;
  }

  body.tsea-member-portal-page:not(.tsea-layout-protected) #content,
  body.tsea-member-portal-page:not(.tsea-layout-protected) #primary,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .content-area,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .site-main,
  body.tsea-member-portal-page:not(.tsea-layout-protected) article,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .entry-content,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .post-entry,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .page-content {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin-left:0 !important;
    margin-right:0 !important;
    box-sizing:border-box !important;
  }

  /* Legacy portal title/banner: never retain its desktop canvas width. */
  body.tsea-member-portal-page:not(.tsea-layout-protected) .entry-title,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .page-title,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .title,
  body.tsea-member-portal-page:not(.tsea-layout-protected) h1 {
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
    overflow-wrap:anywhere !important;
  }

  /* Portal content gets the same usable phone inset as the rest of the site. */
  body.tsea-member-portal-page:not(.tsea-layout-protected) .entry-content,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .post-entry,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .page-content {
    padding-left:30px !important;
    padding-right:30px !important;
  }

  /* Old portal widgets/forms/accordions must shrink with their parent instead of
     preserving desktop widths. */
  body.tsea-member-portal-page:not(.tsea-layout-protected) .entry-content > *,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .post-entry > *,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .page-content > *,
  body.tsea-member-portal-page:not(.tsea-layout-protected) form,
  body.tsea-member-portal-page:not(.tsea-layout-protected) fieldset,
  body.tsea-member-portal-page:not(.tsea-layout-protected) table,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .ui-accordion,
  body.tsea-member-portal-page:not(.tsea-layout-protected) .accordion {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  body.tsea-member-portal-page:not(.tsea-layout-protected) input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=button]),
  body.tsea-member-portal-page:not(.tsea-layout-protected) select,
  body.tsea-member-portal-page:not(.tsea-layout-protected) textarea {
    max-width:100% !important;
    box-sizing:border-box !important;
  }

  body.tsea-member-portal-page:not(.tsea-layout-protected) img,
  body.tsea-member-portal-page:not(.tsea-layout-protected) iframe {
    max-width:100% !important;
    height:auto;
  }
}


/* v1.0.29 — ONLY center the existing Member Portal blue title on mobile. */
@media screen and (max-width:900px) {
  body.tsea-member-portal-page .tsea-se-member-portal-bluebar {
    position:relative !important;
    overflow:hidden !important;
  }
  body.tsea-member-portal-page .tsea-se-member-portal-title {
    position:absolute !important;
    inset:0 !important;
    width:100% !important;
    max-width:none !important;
    min-width:0 !important;
    margin:0 !important;
    padding:0 18px !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    text-align:center !important;
    white-space:nowrap !important;
    box-sizing:border-box !important;
    left:0 !important;
    right:0 !important;
    transform:none !important;
  }
}


/* v1.0.31 — exact Avenue Member Portal title structure, MOBILE ONLY.
   Verified markup: #fullwidth > .member-portal-header > .post-heading > h1 */
@media screen and (max-width:900px) {
  body.page-template-member-page #fullwidth > .member-portal-header {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin-left:0 !important;
    margin-right:0 !important;
    box-sizing:border-box !important;
  }

  body.page-template-member-page #fullwidth > .member-portal-header > .post-heading {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    padding-left:0 !important;
    padding-right:0 !important;
    float:none !important;
    left:auto !important;
    right:auto !important;
    transform:none !important;
    text-align:center !important;
    box-sizing:border-box !important;
  }

  body.page-template-member-page #fullwidth > .member-portal-header > .post-heading > h1 {
    position:static !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    padding-left:16px !important;
    padding-right:16px !important;
    left:auto !important;
    right:auto !important;
    top:auto !important;
    transform:none !important;
    float:none !important;
    display:block !important;
    text-align:center !important;
    white-space:normal !important;
    box-sizing:border-box !important;
  }
}


/* v1.0.32 — logged-in Member Portal mobile header offset + portal banner only. */
@media screen and (max-width:900px) {
  /* WordPress' mobile admin toolbar is fixed and 46px tall. Keep our fixed
     white mobile header immediately below it instead of underneath it. */
  body.admin-bar.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) {
    padding-top:124px !important; /* 46px admin bar + existing 78px mobile header */
  }
  body.admin-bar.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .mob-menu-header-holder {
    top:46px !important;
  }

  /* Logged-in portal landing template does not output the title band. The JS
     below adds the same Avenue class structure; these rules are only a fallback
     to guarantee the familiar blue band and centered title on mobile. */
  body.tsea-member-portal-page .tsea-se-generated-portal-header {
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:150px !important;
    margin:0 !important;
    padding:0 !important;
    background:linear-gradient(90deg,#1c2a58 0%,#24478d 100%) !important;
    box-sizing:border-box !important;
    position:relative !important;
    overflow:hidden !important;
  }
  body.tsea-member-portal-page .tsea-se-generated-portal-header > .post-heading {
    position:absolute !important;
    inset:0 !important;
    width:100% !important;
    height:100% !important;
    margin:0 !important;
    padding:0 !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    text-align:center !important;
  }
  body.tsea-member-portal-page .tsea-se-generated-portal-header > .post-heading > h1 {
    color:#fff !important;
    font-size:clamp(28px,8vw,42px) !important;
    line-height:1.1 !important;
    font-weight:700 !important;
    margin:0 !important;
    padding:0 18px !important;
    width:100% !important;
    text-align:center !important;
    white-space:nowrap !important;
    box-sizing:border-box !important;
  }
}

/* v1.0.33 — Member Portal mobile tap/click restoration only.
   Portal links are valid on desktop. Keep them above any legacy decorative/
   layout layers that can intercept touch events on the mobile template. */
@media screen and (max-width:900px) {
  body.tsea-member-portal-page #fullwidth,
  body.tsea-member-portal-page #fullwidth .member-portal,
  body.tsea-member-portal-page #fullwidth .wp-block-columns.member-portal {
    position:relative !important;
  }

  body.tsea-member-portal-page #fullwidth a {
    position:relative !important;
    z-index:20 !important;
    pointer-events:auto !important;
    touch-action:manipulation !important;
  }

  /* Decorative pseudo-elements must never sit in the touch layer. */
  body.tsea-member-portal-page #fullwidth .member-portal::before,
  body.tsea-member-portal-page #fullwidth .member-portal::after,
  body.tsea-member-portal-page #fullwidth .wp-block-columns.member-portal::before,
  body.tsea-member-portal-page #fullwidth .wp-block-columns.member-portal::after {
    pointer-events:none !important;
  }

  /* The generated title band is visual/navigation context only. */
  body.tsea-member-portal-page .tsea-se-generated-portal-header,
  body.tsea-member-portal-page .tsea-se-generated-portal-header * {
    pointer-events:none !important;
  }
}


/* v1.0.35 — mobile logged-in Member Portal title band.
   The member-page template can retain the Avenue header node while hiding it.
   Re-enable that VERIFIED node on mobile instead of generating a second banner. */
@media screen and (max-width:900px) {
  body.page-template-member-page #fullwidth > .member-portal-header {
    display:block !important;
    visibility:visible !important;
    position:relative !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:150px !important;
    min-height:150px !important;
    margin:0 !important;
    padding:0 !important;
    overflow:hidden !important;
  }
  body.page-template-member-page #fullwidth > .member-portal-header > .post-heading {
    display:flex !important;
    visibility:visible !important;
    position:absolute !important;
    inset:0 !important;
    width:100% !important;
    height:100% !important;
    margin:0 !important;
    padding:0 16px !important;
    align-items:center !important;
    justify-content:center !important;
    box-sizing:border-box !important;
    text-align:center !important;
  }
  body.page-template-member-page #fullwidth > .member-portal-header > .post-heading > h1 {
    display:block !important;
    visibility:visible !important;
    position:static !important;
    width:100% !important;
    margin:0 !important;
    padding:0 !important;
    transform:none !important;
    text-align:center !important;
    white-space:nowrap !important;
  }
}

/* v1.0.36 — mobile About video containment only. */
@media screen and (max-width:900px) {
  body.tsea-about-page:not(.tsea-layout-protected) iframe,
  body.tsea-about-page:not(.tsea-layout-protected) .wp-block-embed,
  body.tsea-about-page:not(.tsea-layout-protected) .wp-block-embed__wrapper,
  body.tsea-about-page:not(.tsea-layout-protected) .video-container,
  body.tsea-about-page:not(.tsea-layout-protected) .embed-container {
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }
  body.tsea-about-page:not(.tsea-layout-protected) iframe[src*="youtube.com"],
  body.tsea-about-page:not(.tsea-layout-protected) iframe[src*="youtu.be"],
  body.tsea-about-page:not(.tsea-layout-protected) iframe[src*="youtube-nocookie.com"] {
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    height:auto !important;
    aspect-ratio:16 / 9 !important;
    margin-left:0 !important;
    margin-right:0 !important;
  }
}

/* v1.0.37 — protected application pages: Avenue mobile shell containment.
   Field Tools and Voting Center remain protected from Site Experience's
   content/sidebar rewriting. This fixes only Avenue's OUTER desktop-width
   canvas on phones so those applications receive the real viewport width. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout.tsea-layout-protected,
  body.tsea-fullwidth-layout.tsea-layout-protected #wrapper,
  body.tsea-fullwidth-layout.tsea-layout-protected #page,
  body.tsea-fullwidth-layout.tsea-layout-protected .site,
  body.tsea-fullwidth-layout.tsea-layout-protected #content,
  body.tsea-fullwidth-layout.tsea-layout-protected #primary,
  body.tsea-fullwidth-layout.tsea-layout-protected .content-area,
  body.tsea-fullwidth-layout.tsea-layout-protected .site-main,
  body.tsea-fullwidth-layout.tsea-layout-protected #wrapper-content,
  body.tsea-fullwidth-layout.tsea-layout-protected #fullwidth,
  body.tsea-fullwidth-layout.tsea-layout-protected .entry-content,
  body.tsea-fullwidth-layout.tsea-layout-protected .page-content,
  body.tsea-fullwidth-layout.tsea-layout-protected .post-entry,
  body.tsea-fullwidth-layout.tsea-layout-protected article {
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    margin-left:0 !important;
    margin-right:0 !important;
    box-sizing:border-box !important;
  }

  body.tsea-fullwidth-layout.tsea-layout-protected {
    overflow-x:hidden !important;
  }

  /* Do not redesign the application; only prevent its own top-level wrapper
     from inheriting a desktop minimum width from Avenue. */
  body.tsea-fullwidth-layout.tsea-layout-protected .tft-app {
    width:100% !important;
    min-width:0 !important;
    max-width:1100px !important;
    box-sizing:border-box !important;
  }
}


/* v1.0.38 — protected app pages on phones: use Avenue's ACTUAL sidebar row.
   v1.0.37 constrained generic IDs, but Avenue's desktop float/grid still
   reserved a sidebar column. The layout detector now tags the real common row
   and content branch on protected pages at mobile widths. Collapse only that
   Avenue shell; do not style the application UI itself. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout.tsea-layout-protected #secondary,
  body.tsea-fullwidth-layout.tsea-layout-protected #sidebar,
  body.tsea-fullwidth-layout.tsea-layout-protected .sidebar,
  body.tsea-fullwidth-layout.tsea-layout-protected .sidebar-right,
  body.tsea-fullwidth-layout.tsea-layout-protected .right-sidebar,
  body.tsea-fullwidth-layout.tsea-layout-protected aside.sidebar,
  body.tsea-fullwidth-layout.tsea-layout-protected aside.widget-area {
    display:none !important;
  }

  body.tsea-fullwidth-layout.tsea-layout-protected .tsea-avenue-sidebar-row,
  body.tsea-fullwidth-layout.tsea-layout-protected .tsea-avenue-content-branch {
    display:block !important;
    float:none !important;
    clear:both !important;
    position:relative !important;
    left:auto !important;
    right:auto !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    margin-left:0 !important;
    margin-right:0 !important;
    padding-left:0 !important;
    padding-right:0 !important;
    box-sizing:border-box !important;
  }

  body.tsea-fullwidth-layout.tsea-layout-protected .tft-app {
    width:auto !important;
    min-width:0 !important;
    max-width:1100px !important;
    margin-left:16px !important;
    margin-right:16px !important;
    box-sizing:border-box !important;
  }

  body.tsea-fullwidth-layout.tsea-layout-protected .tft-login {
    width:auto !important;
    min-width:0 !important;
    max-width:440px !important;
    margin-left:auto !important;
    margin-right:auto !important;
  }
}


/* v1.0.39 — one clean mobile canvas across the legacy TSEA site.
   Keep the proven width/containment rules above. This pass only normalizes the
   visible Avenue shell: no legacy texture, one white canvas, and one 16px grid.
   Purpose-built applications keep control of their internal components. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout:not(.tsea-homepage-active),
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #wrapper,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #page,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #content,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #primary,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .content-area,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .site-main,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #wrapper-content,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) #fullwidth,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-avenue-sidebar-row,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-avenue-content-branch {
    background-color:#fff !important;
    background-image:none !important;
  }

  /* Standard pages: replace the older 30px legacy inset with the sitewide
     mobile grid. Existing page internals remain otherwise untouched. */
  body.tsea-fullwidth-layout:not(.tsea-layout-protected):not(.tsea-homepage-active) .tsea-avenue-content-branch {
    padding-left:16px !important;
    padding-right:16px !important;
  }

  /* Protected apps already own their internals; give only the app shell the
     same 16px edge spacing. Do not add a second inset to their controls. */
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .tft-app {
    margin-left:16px !important;
    margin-right:16px !important;
  }

  /* Remove Avenue's decorative texture from article/page wrappers too, while
     leaving deliberately styled child cards, banners and application panels. */
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) article,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .post-entry,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .entry-content,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .page-content {
    background-image:none !important;
  }
}


/* v1.0.40 — protected app pages: keep the centered TSEA logo with the already-sticky
   mobile controls. The protected-page exclusion left Avenue's #logo in document flow,
   so the hamburger stayed while the logo scrolled away. This changes positioning only. */
@media screen and (max-width:900px) {
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #logo {
    position:fixed !important;
    top:0 !important;
    left:50% !important;
    transform:translateX(-50%) !important;
    width:240px !important;
    max-width:calc(100% - 150px) !important;
    height:78px !important;
    margin:0 !important;
    padding:0 !important;
    z-index:99998 !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    background:transparent !important;
  }
  body.admin-bar.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #logo {
    top:46px !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #logo a {
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    width:100% !important;
    height:78px !important;
    margin:0 !important;
    padding:0 !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #logo img {
    display:block !important;
    width:210px !important;
    max-width:100% !important;
    max-height:64px !important;
    height:auto !important;
    margin:0 auto !important;
    object-fit:contain !important;
  }
}


/* v1.0.41 — final mobile shell cleanup.
   1) Protected apps use the exact same proven Mobile Menu header as the rest of the site.
   2) Chapter detail pages do not repeat TSEA branding beneath that universal header.
   3) Footer-local duplicate umbrellas are suppressed; the original bottom-right trigger remains. */
@media screen and (max-width:900px) {
  /* Field Tools / Voting Center: same fixed shell as ordinary interior pages. */
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) {
    padding-top:78px !important;
  }
  body.admin-bar.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) {
    padding-top:124px !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #header,
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) #logo {
    display:none !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mob-menu-header-holder {
    background:#fff !important;
    display:block !important;
    visibility:visible !important;
    position:fixed !important;
    top:0 !important;
    right:0 !important;
    bottom:auto !important;
    left:0 !important;
    width:100% !important;
    height:78px !important;
    min-height:78px !important;
    margin:0 !important;
    padding:0 !important;
    overflow:visible !important;
    z-index:99999 !important;
  }
  body.admin-bar.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mob-menu-header-holder {
    top:46px !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mob-menu-logo-holder {
    background:transparent !important;
    display:block !important;
    visibility:visible !important;
    position:absolute !important;
    top:0 !important;
    left:50% !important;
    width:240px !important;
    max-width:calc(100% - 150px) !important;
    height:78px !important;
    margin:0 !important;
    padding:0 !important;
    overflow:hidden !important;
    transform:translateX(-50%) !important;
    font-size:0 !important;
    line-height:0 !important;
    z-index:2 !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mob-menu-logo-holder > * {
    display:none !important;
    visibility:hidden !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mob-menu-logo-holder::before {
    content:"" !important;
    display:block !important;
    width:240px !important;
    max-width:100% !important;
    height:68px !important;
    margin:5px auto !important;
    background:url("https://tseaonline.org/wp-content/uploads/2019-Banner-Logo.png") center / contain no-repeat !important;
  }
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mobmenul-container,
  body.tsea-fullwidth-layout.tsea-layout-protected:not(.tsea-homepage-active) .mobmenu-left-bt {
    display:block !important;
    visibility:visible !important;
    position:absolute !important;
    left:14px !important;
    top:15px !important;
    z-index:5 !important;
  }

  /* Never show a second decorative umbrella in the rebuilt footer. */
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer .tsea-game-umbrella,
  body.tsea-fullwidth-layout:not(.tsea-homepage-active) .tsea-modern-legacy-footer .tsea-footer-original-umbrella {
    display:none !important;
  }
}
