/* ============================================================
   SIFU — base.css
   Design tokens, reset, typography, buttons, shared chrome.
   ============================================================ */

:root {
  /* Brand */
  --navy-900: #061225;
  --navy-800: #0a1b33;
  --navy-700: #102b4d;
  --blue-700: #0f3bbf;
  --blue-600: #1c4ed8;
  --blue-500: #2f6bff;
  --blue-300: #9db9ff;
  --blue-100: #dbe6ff;
  --blue-50: #eef4ff;

  /* Neutrals */
  --ink: #0d1a2b;
  --ink-2: #24374f;
  --muted: #5b6b82;
  --muted-2: #7c8aa0;
  --line: #e2e8f2;
  --line-2: #eef2f8;
  --paper: #ffffff;
  --soft: #f5f8fd;
  --soft-2: #eef3fb;

  /* Accent */
  --amber: #f5a524;
  --amber-soft: #fff5e2;
  --green: #0e9f6e;
  --green-soft: #e7f8f1;

  /* Shape */
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(13, 26, 43, .06), 0 1px 3px rgba(13, 26, 43, .05);
  --shadow-md: 0 8px 24px -10px rgba(13, 26, 43, .18), 0 2px 6px rgba(13, 26, 43, .04);
  --shadow-lg: 0 30px 70px -35px rgba(9, 24, 48, .45), 0 12px 30px -20px rgba(9, 24, 48, .3);

  --font: "Plus Jakarta Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --wrap: 1200px;
  --gutter: clamp(20px, 5vw, 48px);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16.5px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 700;
  letter-spacing: -.022em;
  line-height: 1.1;
  color: var(--navy-800);
  text-wrap: balance;
}

h1 { font-size: clamp(2.3rem, 5.2vw, 4rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.85rem, 3.6vw, 2.9rem); letter-spacing: -.03em; }
h3 { font-size: clamp(1.1rem, 1.6vw, 1.3rem); letter-spacing: -.015em; }
h4 { font-size: 1rem; }

p { margin: 0; text-wrap: pretty; }

a { color: inherit; text-decoration: none; }

img, svg { display: block; max-width: 100%; }

button, input, select, textarea { font: inherit; color: inherit; }

ul, ol { margin: 0; padding: 0; list-style: none; }

:focus-visible {
  outline: 2.5px solid var(--blue-500);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--blue-100); color: var(--navy-900); }

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 12px 18px;
  border-radius: var(--r-sm);
  background: var(--navy-800);
  color: #fff;
  font-weight: 600;
  transition: top .18s ease;
}
.skip-link:focus { top: 14px; }

/* ---------- Layout ---------- */

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: clamp(64px, 8vw, 118px); }
.section--tight { padding-block: clamp(52px, 6vw, 84px); }
.section--soft { background: var(--soft); }
.section--ink { background: var(--navy-800); color: #dfe8f6; }
.section--ink h2, .section--ink h3 { color: #fff; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: .73rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--blue-600);
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  opacity: .55;
}
.section--ink .eyebrow { color: var(--blue-300); }

.lede {
  margin-top: 18px;
  font-size: clamp(1rem, 1.5vw, 1.125rem);
  color: var(--muted);
  max-width: 62ch;
  line-height: 1.7;
}
.section--ink .lede { color: #a9bcd8; }

.section-head { max-width: 760px; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow::before { display: none; }
.section-head--center .lede { margin-inline: auto; }

/* ---------- Buttons ---------- */

.btn {
  --btn-bg: var(--blue-600);
  --btn-fg: #fff;
  --btn-border: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 22px;
  border: 1px solid var(--btn-border);
  border-radius: var(--r-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: .94rem;
  font-weight: 650;
  letter-spacing: -.01em;
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease, color .16s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn svg { width: 17px; height: 17px; flex: none; }

.btn--primary {
  box-shadow: 0 12px 26px -14px rgba(28, 78, 216, .85);
}
.btn--primary:hover { box-shadow: 0 18px 34px -16px rgba(28, 78, 216, .9); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--navy-800);
  --btn-border: var(--line);
}
.btn--ghost:hover { --btn-border: var(--blue-300); --btn-bg: var(--blue-50); }

.btn--light {
  --btn-bg: #fff;
  --btn-fg: var(--navy-800);
}
.btn--light:hover { --btn-bg: var(--blue-50); }

.btn--outline-light {
  --btn-bg: transparent;
  --btn-fg: #e8effa;
  --btn-border: rgba(255, 255, 255, .26);
}
.btn--outline-light:hover { --btn-bg: rgba(255, 255, 255, .1); --btn-border: rgba(255, 255, 255, .5); }

.btn--lg { padding: 15px 26px; font-size: 1rem; }
.btn--sm { padding: 9px 16px; font-size: .85rem; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.site-header.is-stuck {
  border-bottom-color: var(--line);
  box-shadow: 0 10px 30px -24px rgba(9, 24, 48, .5);
}

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  height: 74px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 800;
  letter-spacing: -.03em;
  font-size: 1.28rem;
  color: var(--navy-900);
  flex: none;
}
.brand__mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--blue-500), var(--blue-700));
  display: grid;
  place-items: center;
  color: #fff;
  font-size: .95rem;
  font-weight: 800;
  letter-spacing: -.04em;
  box-shadow: 0 6px 16px -8px rgba(28, 78, 216, .9);
}
.brand__tag {
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--blue-600);
  border: 1px solid var(--blue-100);
  background: var(--blue-50);
  padding: 2px 7px;
  border-radius: var(--r-pill);
  transform: translateY(-1px);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-inline: auto;
}
.nav__link {
  position: relative;
  padding: 9px 13px;
  border-radius: var(--r-sm);
  font-size: .905rem;
  font-weight: 550;
  color: var(--ink-2);
  transition: color .15s ease, background .15s ease;
}
.nav__link:hover { color: var(--blue-700); background: var(--blue-50); }
.nav__link.is-active { color: var(--blue-700); }
.nav__link.is-active::after {
  content: "";
  position: absolute;
  left: 13px;
  right: 13px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--blue-500);
}

.nav__actions { display: flex; align-items: center; gap: 8px; }
.nav__login {
  padding: 9px 14px;
  border-radius: var(--r-pill);
  font-size: .9rem;
  font-weight: 600;
  color: var(--ink-2);
}
.nav__login:hover { color: var(--blue-700); background: var(--blue-50); }

.nav__toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: #fff;
  cursor: pointer;
  place-items: center;
}
.nav__toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--navy-800);
  border-radius: 2px;
  position: relative;
}
.nav__toggle span::before,
.nav__toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--navy-800);
  border-radius: 2px;
  transition: transform .2s ease;
}
.nav__toggle span::before { top: -6px; }
.nav__toggle span::after { top: 6px; }
.nav.is-open .nav__toggle span { background: transparent; }
.nav.is-open .nav__toggle span::before { transform: translateY(6px) rotate(45deg); }
.nav.is-open .nav__toggle span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--navy-900);
  color: #93a6c2;
  padding-block: 64px 32px;
  font-size: .92rem;
}
.site-footer a { color: #b9c8dd; }
.site-footer a:hover { color: #fff; }

.footer__top {
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: 36px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.footer__brand .brand { color: #fff; }
.footer__brand p { margin-top: 14px; max-width: 32ch; line-height: 1.65; }
.footer__col h4 {
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #6f86a8;
  margin-bottom: 14px;
  font-weight: 700;
}
.footer__col li + li { margin-top: 9px; }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 24px;
  align-items: center;
  justify-content: space-between;
  padding-top: 26px;
  font-size: .84rem;
  color: #6f86a8;
}
.footer__legal { display: flex; flex-wrap: wrap; gap: 18px; }
.footer__social { display: flex; gap: 10px; }
.footer__social a {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, .14);
  transition: background .15s ease, border-color .15s ease;
}
.footer__social a:hover { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .3); }
.footer__social svg { width: 15px; height: 15px; }

/* ---------- Reveal ---------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .7s cubic-bezier(.22, .61, .36, 1), transform .7s cubic-bezier(.22, .61, .36, 1);
  transition-delay: var(--d, 0ms);
}
[data-reveal].is-in { opacity: 1; transform: none; }

@media (max-width: 960px) {
  .nav__links { display: none; }
  .nav__toggle { display: grid; }
  .nav__login { display: none; }
  .nav.is-open .nav__links {
    display: flex;
    position: absolute;
    inset: 74px 0 auto;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    margin: 0;
    padding: 14px var(--gutter) 22px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
  }
  .nav.is-open .nav__link { padding: 12px 12px; font-size: 1rem; }
  .nav.is-open .nav__link.is-active::after { display: none; }
  .footer__top { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .footer__top { grid-template-columns: 1fr; gap: 26px; }
  .brand__tag { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}
