/* ==========================================================================
   KFINANCIAL - BUILD & PROTECT LEGACY
   Tier 1 brand palette and type system. Do not substitute fonts or colors.
   ========================================================================== */

@font-face {
  font-family: 'Ubuntu';
  src: url('../fonts/Ubuntu-Light.woff2') format('woff2'),
       url('../fonts/Ubuntu-Light.ttf') format('truetype');
  font-weight: 300;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu';
  src: url('../fonts/Ubuntu-Regular.woff2') format('woff2'),
       url('../fonts/Ubuntu-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu';
  src: url('../fonts/Ubuntu-Italic.woff2') format('woff2'),
       url('../fonts/Ubuntu-Italic.ttf') format('truetype');
  font-weight: 400;
  font-style: italic;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu';
  src: url('../fonts/Ubuntu-Medium.woff2') format('woff2'),
       url('../fonts/Ubuntu-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu';
  src: url('../fonts/Ubuntu-Bold.woff2') format('woff2'),
       url('../fonts/Ubuntu-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu Mono';
  src: url('../fonts/UbuntuMono-Regular.woff2') format('woff2'),
       url('../fonts/UbuntuMono-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Ubuntu Mono';
  src: url('../fonts/UbuntuMono-Bold.woff2') format('woff2'),
       url('../fonts/UbuntuMono-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}

:root {
  --ivory: #F5EDD8;
  --parchment: #EDE0C4;
  --navy: #0B1A2A;
  --gold: #D4AF37;
  --warm-white: #F9F9F9;
  --light-grey: #F2F2F2;
  --gold-deep: #AB8A1E;
  --gold-light: #E8D078;

  --font-display: 'Ubuntu', sans-serif;
  --font-mono: 'Ubuntu Mono', monospace;

  --section-pad: clamp(5rem, calc(var(--vw, 1vw) * 10), 9rem);
  --gutter: clamp(1.5rem, calc(var(--vw, 1vw) * 6), 6rem);
  --max-w: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  background: var(--ivory);
  color: var(--navy);
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---- fonts gate / motion states ---- */
body.motion-pending #hero-gate-target,
body.motion-pending [data-reveal],
body.motion-pending [data-split] {
  opacity: 0;
}
body.fonts-ready [data-reveal],
body.fonts-ready [data-split] {
  visibility: visible;
}
body.no-animate [data-reveal],
body.no-animate [data-split],
body.reduced-motion [data-reveal],
body.reduced-motion [data-split] {
  opacity: 1 !important;
  transform: none !important;
  clip-path: none !important;
}
body.no-animate .house-svg,
body.reduced-motion .house-svg { display: none; }
body.no-animate .house-raster,
body.reduced-motion .house-raster { opacity: 1 !important; }

/* ==========================================================================
   NAV
   ========================================================================== */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1.1rem var(--gutter);
  display: flex;
  justify-content: center;
  mix-blend-mode: normal;
}
.nav-inner {
  width: 100%;
  max-width: var(--max-w);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.nav-logo img { height: 42px; width: auto; }
.blend-logo { mix-blend-mode: multiply; }
.btn-text-short { display: none; }

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  padding: 0.75rem 1.5rem;
  border-radius: 2px;
  transition: transform 0.35s cubic-bezier(.22,1,.36,1), background-color 0.35s ease, box-shadow 0.35s ease;
}
.btn-nav {
  background: var(--navy);
  color: var(--ivory);
  border: 1.5px solid var(--gold);
  box-shadow: 0 0 0 1px rgba(212,175,55,0.18), 0 3px 14px rgba(212,175,55,0.3);
}
.btn-nav:hover { transform: translateY(-2px); box-shadow: 0 0 0 1px rgba(212,175,55,0.28), 0 5px 18px rgba(212,175,55,0.4); }
.btn-gold {
  background: var(--gold);
  color: var(--navy);
  font-weight: 700;
}
.btn-gold:hover { background: var(--gold-light); transform: translateY(-2px); }
.btn-large { font-size: 1rem; padding: 1.1rem 2.4rem; }

/* ==========================================================================
   EYEBROW LABEL - gold bar always matches text width (JS enforced)
   ========================================================================== */
br.soft-break { display: none; }
@media (min-width: 480px) {
  br.soft-break { display: inline; }
}

.eyebrow {
  display: inline-block;
  margin-bottom: 1.75rem;
}
.eyebrow-bar {
  display: block;
  height: 2px;
  background: var(--gold);
  width: 100%;
  margin-bottom: 0.65em;
}
.eyebrow-text {
  display: block;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  color: var(--navy);
  font-weight: 400;
}
.eyebrow-light .eyebrow-text { color: var(--ivory); }
.eyebrow-light .eyebrow-bar { background: var(--gold-light); }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--section-pad) + 3rem) var(--gutter) var(--section-pad);
  text-align: center;
  overflow: hidden;
}

.hero-mark {
  position: relative;
  width: min(220px, calc(var(--vw, 1vw) * 40));
  height: auto;
  aspect-ratio: 260 / 220;
  margin-bottom: 2.2rem;
}
.house-svg {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  overflow: visible;
}
.house-svg .stroke {
  fill: none;
  stroke-width: 7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.gold-wall, .gold-roof { stroke: var(--gold); }
.navy-wall, .navy-roof { stroke: var(--navy); }

.house-raster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
}

.hero-copy { max-width: 760px; }
.hero-eyebrow { margin-bottom: 1.5rem; }

.hero-headline {
  font-size: clamp(1.85rem, calc(var(--vw, 1vw) * 8), 4.4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 1.4rem;
  color: var(--navy);
}
.hero-sub {
  font-size: clamp(1.05rem, calc(var(--vw, 1vw) * 2), 1.25rem);
  font-weight: 300;
  max-width: 560px;
  margin: 0 auto 2.4rem;
  color: #26364a;
}

.hero-actions { display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.hero-credential {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  color: #55606e;
  max-width: 480px;
}

.scroll-cue {
  position: absolute;
  bottom: 2.2rem; left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
}
.scroll-cue span {
  width: 1px; height: 42px;
  background: linear-gradient(to bottom, var(--navy), transparent);
}
.scroll-cue p {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  margin: 0;
  color: #55606e;
}

/* ==========================================================================
   MARQUEE
   ========================================================================== */
.marquee-wrap {
  background: var(--navy);
  padding: 0.9rem 0;
  overflow: hidden;
  white-space: nowrap;
  display: flex;
}
.marquee-track {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  padding-right: 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: var(--gold-light);
  flex-shrink: 0;
}
.marquee-track span { white-space: nowrap; }

/* ==========================================================================
   BANDS
   ========================================================================== */
.band {
  padding: var(--section-pad) var(--gutter);
  position: relative;
}
.band-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}
.band-navy {
  background: var(--navy);
  color: var(--ivory);
}
.band-ivory { background: var(--ivory); }
.band-parchment { background: var(--parchment); }
.band-warm-white { background: var(--warm-white); }

.statement {
  font-size: clamp(1.55rem, calc(var(--vw, 1vw) * 6.4), 3.1rem);
  font-weight: 700;
  line-height: 1.18;
  margin: 0 0 2rem;
  max-width: 880px;
  color: var(--ivory);
}
.statement-dark { color: var(--navy); }
.band-copy {
  font-size: 1.08rem;
  font-weight: 300;
  max-width: 640px;
  color: rgba(245,237,216,0.88);
  margin: 0 0 1.1rem;
}
.band-copy-dark { color: #33404f; }
.band-question {
  font-size: 1.3rem;
  font-weight: 400;
  font-style: italic;
  color: var(--gold-light);
  margin-top: 1.6rem;
}
.exclusion-line { margin-top: 2.4rem; max-width: 700px; }

/* ==========================================================================
   BUILDER'S STORY
   ========================================================================== */
.builder-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(2rem, calc(var(--vw, 1vw) * 6), 5rem);
  align-items: center;
}
.builder-photo { position: relative; text-align: center; }
.builder-img {
  max-height: 560px;
  width: auto;
  margin: 0 auto;
}

.stat-strip {
  max-width: var(--max-w);
  margin: clamp(3.5rem, calc(var(--vw, 1vw) * 8), 6rem) auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  border-top: 1px solid rgba(11,26,42,0.15);
  padding-top: 2.8rem;
}
.stat-card { text-align: left; }
.stat-number, .stat-number-static {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.1rem, calc(var(--vw, 1vw) * 4), 2.8rem);
  color: var(--navy);
  margin: 0 0 0.5rem;
  font-variant-numeric: tabular-nums;
}
.stat-label {
  font-size: 0.92rem;
  font-weight: 400;
  color: #4a5563;
  margin: 0;
  max-width: 260px;
}

/* ==========================================================================
   WHO / COVERS GRIDS
   ========================================================================== */
.who-grid, .covers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin: 2.6rem 0 2.4rem;
}

.who-card, .covers-card {
  background: rgba(11,26,42,0.03);
  border: 1px solid rgba(11,26,42,0.1);
  border-radius: 4px;
  padding: 1.9rem 1.7rem;
}
.who-title, .covers-title {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy);
  margin: 0 0 0.6rem;
}
.who-copy, .covers-copy {
  font-size: 0.95rem;
  font-weight: 300;
  color: #43505f;
  margin: 0;
}

/* ==========================================================================
   FINAL CTA
   ========================================================================== */
.cta-inner { text-align: center; margin: 0 auto; }
.cta-headline { margin-left: auto; margin-right: auto; }
.cta-sub { margin-left: auto; margin-right: auto; text-align: center; }
.cta-band .btn-large { margin-top: 0.6rem; }
.cta-contact {
  margin-top: 2.2rem;
  display: flex; gap: 0.9rem; justify-content: center; flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--gold-light);
}
.cta-contact a:hover { color: var(--gold); }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  background: var(--navy);
  padding: 3.5rem var(--gutter) 2.5rem;
  border-top: 1px solid rgba(245,237,216,0.12);
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  text-align: center;
}
.footer-logo { height: 36px; width: auto; margin: 0 auto 1.6rem; }
.footer-legal {
  font-size: 0.78rem;
  font-weight: 300;
  color: rgba(245,237,216,0.55);
  max-width: 680px;
  margin: 0 auto 1.2rem;
  line-height: 1.7;
}
.footer-copyright {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: rgba(245,237,216,0.4);
  margin: 0;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 900px) {
  .builder-grid { grid-template-columns: 1fr; text-align: left; }
  .builder-photo { order: -1; }
  .builder-img { max-height: 380px; }
  .stat-strip { grid-template-columns: 1fr; gap: 1.8rem; }
  .who-grid { grid-template-columns: 1fr; }
  .covers-grid { grid-template-columns: 1fr; }
  .hero-mark { width: clamp(140px, calc(var(--vw, 1vw) * 34), 220px); }
}

@media (max-width: 560px) {
  :root { --section-pad: 4rem; --gutter: 1.25rem; }
  .nav-logo img { height: 32px; }
  .btn-nav { font-size: 0.72rem; padding: 0.55rem 0.9rem; }
  .btn-text-full { display: none; }
  .btn-text-short { display: inline; }
  .statement { max-width: 100%; }
  .hero-credential { font-size: 0.65rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ==========================================================================
   JS-VERIFIED BREAKPOINTS
   Some in-app preview contexts don't report true device width to vw units
   or @media queries (they resolve against a wider virtual canvas). These
   classes are set by an inline script in <head> using screen.width, which
   reads the real device regardless of that quirk. Kept alongside the
   @media rules above, not instead of them, so nothing regresses on normal
   browsers; these simply catch the cases the CSS-only rules miss.
   ========================================================================== */
html.bp-under-900 .builder-grid { grid-template-columns: 1fr !important; text-align: left; }
html.bp-under-900 .builder-photo { order: -1; }
html.bp-under-900 .builder-img { max-height: 380px !important; }
html.bp-under-900 .stat-strip { grid-template-columns: 1fr !important; gap: 1.8rem; }
html.bp-under-900 .who-grid { grid-template-columns: 1fr !important; }
html.bp-under-900 .covers-grid { grid-template-columns: 1fr !important; }
html.bp-under-900 .hero-mark { width: clamp(140px, 34vw, 220px) !important; }

html.bp-under-560 { --section-pad: 4rem; --gutter: 1.25rem; }
html.bp-under-560 .nav-logo img { height: 32px !important; }
html.bp-under-560 .btn-nav { font-size: 0.72rem !important; padding: 0.55rem 0.9rem !important; }
html.bp-under-560 .btn-text-full { display: none !important; }
html.bp-under-560 .btn-text-short { display: inline !important; }
html.bp-under-560 .statement { max-width: 100% !important; }
html.bp-under-560 .hero-credential { font-size: 0.65rem !important; }

html.bp-under-480 br.soft-break { display: none !important; }
html.bp-under-560 .eyebrow-text {
  font-size: 0.64rem !important;
  letter-spacing: 0.09em !important;
}
html.bp-under-560 .hero-headline,
html.bp-under-560 .statement {
  overflow-wrap: break-word;
  word-break: break-word;
}
