/* Fixed chessboard backdrop — no falling pieces. */

.site-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(ellipse 90% 60% at 70% 20%, rgba(0, 80, 160, 0.22), transparent 55%),
    radial-gradient(ellipse 70% 50% at 15% 85%, rgba(0, 29, 81, 0.5), transparent 60%),
    linear-gradient(165deg, #01030f 0%, #061428 40%, #01030f 100%);
}

/* Chessboard photo — fixed with .site-bg (does not scroll away) */
.site-bg__board {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: min(100vh, 920px);
  background:
    linear-gradient(105deg, rgba(1, 3, 15, 0.55) 0%, rgba(1, 3, 15, 0.2) 45%, rgba(1, 3, 15, 0.15) 70%, rgba(1, 3, 15, 0.45) 100%),
    linear-gradient(180deg, rgba(1, 3, 15, 0.1) 0%, rgba(1, 3, 15, 0.35) 70%, rgba(1, 3, 15, 0.95) 100%),
    url("bgr-hero.webp") center 38% / cover no-repeat;
}

.site-bg__veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(1, 3, 15, 0.12) 0%, rgba(1, 3, 15, 0.22) 42%, rgba(1, 3, 15, 0.88) 100%),
    linear-gradient(90deg, rgba(1, 3, 15, 0.5) 0%, rgba(1, 3, 15, 0.1) 52%, rgba(1, 3, 15, 0.3) 100%);
}

body.with-site-bg {
  background: transparent;
}

body.with-site-bg>*:not(.site-bg):not(.preview-banner) {
  position: relative;
  z-index: 1;
}

body.with-site-bg .preview-banner {
  position: relative;
  z-index: 9999;
}

/* Nav scroll styles: assets/nav-scroll.css */

/* Hero: transparent — board is in fixed .site-bg__board */
body.with-site-bg .hero {
  background: transparent !important;
  background-image: none !important;
  isolation: auto;
  min-height: min(88vh, 820px);
  display: flex;
  align-items: center;
}

body.with-site-bg .hero::after {
  display: none;
}

body.with-site-bg .hero>.wrap {
  width: min(var(--max, 1280px), calc(100% - 2 * var(--3xl, 32px)));
  margin-left: auto;
  margin-right: auto;
}

body.with-site-bg .section,
body.with-site-bg .footer,
body.with-site-bg .band {
  background: transparent;
}

body.with-site-bg .card,
body.with-site-bg .code-mockup,
body.with-site-bg .info-diagram,
body.with-site-bg .form-shell,
body.with-site-bg .contact-card {
  background: rgba(1, 3, 15, 0.62);
  backdrop-filter: blur(10px);
}

body.with-site-bg .hero-copy .display-xl,
body.with-site-bg .hero-copy .body-lg {
  text-shadow: 0 2px 24px rgba(1, 3, 15, 0.85);
}

.metaphor-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  margin-bottom: 18px;
  padding: 6px 12px;
  border: 1px solid rgba(0, 180, 255, 0.28);
  border-radius: 2px;
  background: rgba(0, 29, 81, 0.45);
  color: #a8d8ff;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.35;
  max-width: 420px;
  backdrop-filter: blur(8px);
}

.metaphor-chip svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: 0.9;
}

@media (max-width: 767px) {
  .site-bg__board {
    height: 100svh;
  }
}