/* ===================================
   B&D Communications — Styles
   =================================== */

:root {
  --color-light-blue-tint: rgba(152, 192, 217, 0.12);
}

/* ===================================
   Reset & Base
   =================================== */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: inherit;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--wp--preset--font-family--oswald);
  font-weight: 600;
  line-height: 1.2;
  color: var(--wp--preset--color--base);
}

/* ===================================
   Shared Heading Styles
   =================================== */

.section-heading {
  font-family: var(--wp--preset--font-family--oswald);
  font-size: var(--wp--preset--font-size--huge);
  font-weight: 600;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--wp--preset--color--base);
  margin-bottom: var(--wp--preset--spacing--30);
}

.section-heading--light {
  color: var(--wp--preset--color--base-3);
}

.section-subheading {
  font-family: var(--wp--preset--font-family--open-sans);
  font-size: var(--wp--preset--font-size--lg);
  font-weight: 500;
  color: var(--wp--preset--color--contrast-2);
  max-width: var(--wp--style--global--content-size);
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes countUp {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

.animate-on-scroll {
  opacity: 1;
  transform: translateY(0);
}

.js .animate-on-scroll:not(.is-visible) {
  opacity: 0;
  transform: translateY(30px);
}

.js .animate-on-scroll {
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.js .animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.js .animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.js .animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.js .animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }
.js .animate-on-scroll:nth-child(5) { transition-delay: 0.4s; }
.js .animate-on-scroll:nth-child(6) { transition-delay: 0.5s; }

/* WordPress Admin Bar Offsets
   -------------------------------------------------------------------------- */
.admin-bar .nav,
.admin-bar [class*="nav"][style*="position: fixed"],
.admin-bar [class*="header"][style*="position: fixed"] {
  top: 32px;
}

@media screen and (max-width: 782px) {
.admin-bar .nav,
  .admin-bar [class*="nav"][style*="position: fixed"],
  .admin-bar [class*="header"][style*="position: fixed"] {
    top: 46px;
}
}

/* Navigation — Parent-level rules (can't scope to nav block)
   -------------------------------------------------------------------------- */
.wp-block-template-part:has(.wp-block-navigation .is-menu-open),
header:has(.wp-block-navigation .is-menu-open) {
  z-index: 100001;
  position: relative;
}

header.wp-block-template-part:has(.is-position-sticky),
header.wp-block-template-part:has([style*="position:sticky"]),
header.wp-block-template-part:has([style*="position: sticky"]) {
  display: contents;
}

footer.wp-block-template-part,
footer.wp-block-template-part > .wp-block-group {
  position: relative;
  z-index: 1;
}

[class*="site-footer"],
[class*="footer-section"] {
  margin-block-start: 0 !important;
}

/* Header Scroll Behavior
   -------------------------------------------------------------------------- */
.theme-header-transparent-until-scroll {
  transition: background-color 0.3s ease;
  z-index: 100 !important;
  &:not(.is-scrolled) {
    background-color: transparent !important;
  }

  &:not(.is-scrolled) > * {
    background-color: transparent !important;
  }
}