/* =========================================================
   CLUB49 design kit (child theme)
   Shared by both homepage versions (custom modules + native).
   Tokens and component classes (.bb-btn, .bb-chip, ...) live in
   the BB AI design system "CLUB49"; this file holds what must
   work outside it: page shell, noise, reveal, safety nets.
   ========================================================= */

/* ---- Page shell (body.c49-page) ---- */
html:has(body.c49-page) {
  scroll-behavior: smooth;
}
body.c49-page {
  background: #0E1310;
  color: #1A231C;
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  line-height: 1.55;
  overflow-x: hidden;
}
body.c49-page #page,
body.c49-page .site-content,
body.c49-page .site-content > .ast-container,
body.c49-page #primary,
body.c49-page .ast-article-single,
body.c49-page .entry-content {
  max-width: none !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent;
}
body.c49-page .site-content > .ast-container {
  display: block;
}
body.c49-page .entry-header,
body.c49-page .ast-breadcrumbs-wrapper {
  display: none;
}

/* Paper noise over the whole page (original: body::after, 4.5%) */
body.c49-page::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 130;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.045'/%3E%3C/svg%3E");
}

/* ---- Reveal (.bb-r -> .in), only when JS runs ---- */
html.c49-js body.c49-page .bb-r {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .9s cubic-bezier(.2,.6,.2,1), transform .9s cubic-bezier(.2,.6,.2,1);
}
html.c49-js body.c49-page .bb-r.in {
  opacity: 1;
  transform: none;
}
body.c49-page .bb-d1 { transition-delay: .12s !important; }
body.c49-page .bb-d2 { transition-delay: .24s !important; }
body.c49-page .bb-d3 { transition-delay: .38s !important; }
body.c49-page .bb-d4 { transition-delay: .52s !important; }
body.c49-page .bb-d5 { transition-delay: .66s !important; }
/* In the Beaver Builder editor everything shows */
html.fl-builder-edit body.c49-page .bb-r,
body.fl-builder-edit.c49-page .bb-r {
  opacity: 1 !important;
  transform: none !important;
}

/* ---- Buttons are never underlined (stack rule) ---- */
body.c49-page .bb-btn,
body.c49-page .bb-btn:hover,
body.c49-page .bb-btn:focus,
body.c49-page .bb-btn:visited,
body.c49-page a.fl-button,
body.c49-page a.fl-button:hover,
body.c49-page a.fl-button:focus,
body.c49-page a.fl-button:visited {
  text-decoration: none !important;
}

/* ---- Component corrections shared by both versions ---- */
/* Buttons: original .btn inherits line-height 1.55; only ghost buttons carry a border */
body.c49-page .bb-btn {
  line-height: 1.55;
  border-width: 0;
}
body.c49-page .bb-btn.bb-btn-ghost-l,
body.c49-page .bb-btn.bb-btn-ghost-d {
  border-width: 1px;
  border-style: solid;
}
/* Machine & magie panels keep their hover-grow transition next to the reveal */
html.c49-js body.c49-page .mm-panel.bb-r {
  transition: flex .6s cubic-bezier(.25,.7,.25,1), opacity .9s cubic-bezier(.2,.6,.2,1), transform .9s cubic-bezier(.2,.6,.2,1);
}

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  body.c49-page *,
  body.c49-page *::before,
  body.c49-page *::after {
    animation: none !important;
    transition-duration: .01ms !important;
  }
  html.c49-js body.c49-page .bb-r {
    opacity: 1;
    transform: none;
  }
}
