/* Shared Header — styled like original main menu */

:root {
  --site-header-h: 66px;
  --site-header-gap: 28px;
  --site-content-max: 1180px;
  --site-content-x: 40px;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 220;
  border-bottom: 1px solid #e7edf9;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}

.site-header-inner {
  max-width: var(--site-content-max);
  margin: 0 auto;
  padding: 0 var(--site-content-x);
  height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: nowrap;
}

.site-header-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: #0d0f14;
  font-family: "Manrope", sans-serif;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

.site-header-logo span {
  color: #3a5cff;
}

.site-header-right {
  display: flex;
  align-items: center;
  gap: 30px;
  min-width: 0;
}

.site-header-links {
  display: flex;
  align-items: center;
  gap: 28px;
  white-space: nowrap;
}

.site-header-links a {
  font-family: "Manrope", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #586074;
  text-decoration: none;
  transition: color 0.2s;
}

.site-header-links a:hover,
.site-header-links a.is-active {
  color: #3a5cff;
}

.site-header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 999px;
  text-decoration: none;
  font-family: "Manrope", sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.005em;
  color: #fff;
  background: #0d0f14;
  white-space: nowrap;
  transition: background 0.2s, transform 0.2s;
}

.site-header-cta:hover {
  background: #20243a;
  transform: translateY(-1px);
}

.site-header-cta-short {
  display: none;
}

.site-header-mobile {
  display: none;
}

.site-header-burger {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid #d9e2f3;
  border-radius: 10px;
  background: #fff;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.site-header-burger span {
  display: block;
  width: 16px;
  height: 2px;
  background: #0d0f14;
  position: relative;
}

.site-header-burger span::before,
.site-header-burger span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  background: #0d0f14;
}

.site-header-burger span::before {
  top: -5px;
}

.site-header-burger span::after {
  top: 5px;
}

body.has-site-header {
  scroll-padding-top: var(--site-header-h);
}

/* ── Unified offset below fixed header — ONE place only ── */
body.has-site-header > section#hero,
body.has-site-header .wrap,
body.has-site-header .pg,
body.has-site-header .ft-main {
  padding-top: calc(var(--site-header-h) + var(--site-header-gap));
}

/* Nested content blocks must NOT stack offset (e.g. UX test #hero inside .wrap) */
body.has-site-header .wrap .hero,
body.has-site-header .pg .hero,
body.has-site-header .wrap #hero,
body.has-site-header .pg #hero {
  padding-top: 0;
  min-height: auto;
}

/* Top-level article heroes (direct on page, not inside .wrap/.pg) */
body.has-site-header > .hero,
body.has-site-header > script + .hero,
body.has-site-header > script + section.hero {
  min-height: auto;
  padding-top: calc(var(--site-header-h) + var(--site-header-gap));
}

/* Diagnostic test: landing vertically centered, quiz/result — normal offset */
body.has-site-header #ld.scr.on {
  min-height: 100vh;
  padding-top: var(--site-header-h);
  box-sizing: border-box;
}

body.has-site-header #ld .pg {
  padding-top: 0;
}

body.has-site-header #hyp .pg,
body.has-site-header #qz .pg,
body.has-site-header #res .pg {
  padding-top: calc(var(--site-header-h) + var(--site-header-gap));
}

/* Dark header — founder-traps result / other dark screens */
body.is-dark-header .site-header {
  border-bottom-color: rgba(255, 255, 255, 0.08);
  background: rgba(8, 11, 22, 0.9);
}

body.is-dark-header .site-header-logo { color: #fff; }
body.is-dark-header .site-header-logo span { color: #7b9aff; }

body.is-dark-header .site-header-links a {
  color: rgba(255, 255, 255, 0.72);
}

body.is-dark-header .site-header-links a:hover,
body.is-dark-header .site-header-links a.is-active {
  color: #fff;
}

body.is-dark-header .site-header-cta {
  background: #fff;
  color: #0d0f14;
}

body.is-dark-header .site-header-cta:hover {
  background: #eef1fb;
  transform: translateY(-1px);
}

body.is-dark-header .site-header-burger {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.06);
}

body.is-dark-header .site-header-burger span,
body.is-dark-header .site-header-burger span::before,
body.is-dark-header .site-header-burger span::after {
  background: #fff;
}

body.is-dark-header .site-header-mobile {
  background: rgba(8, 11, 22, 0.98);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

body.is-dark-header .site-header-mobile a {
  color: rgba(255, 255, 255, 0.78);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

@media (max-width: 1040px) {
  .site-header-links {
    display: none;
  }

  .site-header-burger {
    display: inline-flex;
  }

  .site-header-mobile {
    display: none;
    position: absolute;
    top: 66px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid #e7edf9;
    padding: 10px 16px 16px;
  }

  .site-header-mobile.is-open {
    display: flex;
    flex-direction: column;
    gap: 0;
  }

  .site-header-mobile a {
    font-family: "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #586074;
    text-decoration: none;
    padding: 12px 4px;
    border-bottom: 1px solid #f0f4fc;
  }

  .site-header-mobile a:last-child {
    border-bottom: none;
  }

  .site-header-cta {
    padding: 10px 16px;
    font-size: 12px;
  }

  .site-header-cta-full {
    display: none;
  }

  .site-header-cta-short {
    display: inline;
  }
}

@media (max-width: 760px) {
  :root {
    --site-header-h: 60px;
    --site-header-gap: 20px;
    --site-content-x: 16px;
  }

  .site-header-inner {
    padding: 0 var(--site-content-x);
    height: 60px;
  }

  .site-header-mobile {
    top: 60px;
  }
}
