@font-face {
  font-family: "Archivo Expanded";
  src: url("fonts/archivo-expanded-latin.woff2") format("woff2");
  font-weight: 800;
  font-display: swap;
}

:root {
  --primary: #0a0a0c;
  --primary-2: #16171c;
  --accent: #2f5eff;
  --accent-hover: #2447cc;
  --accent-soft: #5b82ff;
  --ink: #0a0a0c;
  --muted: #5c6470;
  --line: #e2e4e8;
  --bg: #ffffff;
  --bg-soft: #f4f5f7;
  --max: 1120px;
  --font-label: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Archivo Expanded", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --diag: 4.5vw;             /* rise of the seam diagonals */
  --skew: -2.6deg;           /* matching skew angle */
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 17px;
  overflow-x: clip;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 28px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.pt-0 { padding-top: 0; }
.mt-md { margin-top: 32px; }

a:focus-visible, .btn:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 3px;
}
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 0 0 6px 0; font-weight: 600; text-decoration: none; }
.skip-link:focus { left: 0; }
#main-content { scroll-margin-top: 76px; }

/* ── Reveal on scroll ───────────────────────────── */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .65s ease, transform .65s ease; }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }

/* ── Header ─────────────────────────────────────── */
header {
  background: var(--primary);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 28px;
  max-width: var(--max);
  margin: 0 auto;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.02rem;
  letter-spacing: -0.01em;
  color: #fff;
  text-decoration: none;
}
.logo svg { display: block; flex: none; }
.logo .w2 { font-weight: 800; color: #6a707c; }
nav.links { display: flex; }
nav.links a {
  color: #a8adb6;
  text-decoration: none;
  margin-left: 26px;
  font-family: var(--font-label);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 6px 0;
  display: inline-block;
  background: linear-gradient(var(--accent-soft), var(--accent-soft)) no-repeat 0 100% / 0 2px;
  transition: color .25s ease, background-size .25s ease;
}
nav.links a:hover, nav.links a.active { color: #fff; background-size: 100% 2px; }

/* ── Hero with seam diagonal ────────────────────── */
.hero {
  position: relative;
  background: linear-gradient(160deg, var(--primary) 0%, var(--primary-2) 100%);
  color: #fff;
  padding: 96px 0 calc(72px + var(--diag));
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--diag)), 0 100%);
}
.hero::after {
  content: "";
  position: absolute;
  left: -3%;
  width: 106%;
  bottom: calc(var(--diag) / 2);
  height: 3px;
  background: var(--accent);
  transform: skewY(var(--skew));
}
.hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 5.6vw, 4rem);
  letter-spacing: -0.02em;
  line-height: 1.04;
  max-width: 860px;
  text-wrap: balance;
}
.hero p.lede {
  margin-top: 30px;
  max-width: 620px;
  color: #b9bec7;
  font-size: 1.12rem;
}
.hero .cta-row { margin-top: 38px; }

.hero-icon { display: block; margin-bottom: 22px; position: relative; }

/* brand watermark on dark bands */
.band-mark {
  position: absolute;
  right: -34px;
  top: -26px;
  width: 300px;
  height: 300px;
  opacity: 0.05;
  pointer-events: none;
}
.dark-band > .wrap, .cta-band > .wrap { position: relative; z-index: 1; }

/* ── Buttons ────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 3px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.98rem;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: 0 10px 26px rgba(47,94,255,0.32); }
.btn-ghost { color: #fff; border: 1px solid rgba(255,255,255,0.4); margin-left: 12px; }
.btn-ghost:hover { border-color: #fff; transform: translateY(-2px); }

/* ── Sections ───────────────────────────────────── */
section { padding: 84px 0; }
section.soft { background: var(--bg-soft); }
#services, #contact { scroll-margin-top: 76px; }
h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.6rem, 3.2vw, 2.3rem);
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin-bottom: 18px;
  text-wrap: balance;
}
.section-lede { color: var(--muted); max-width: 620px; margin-bottom: 44px; }
.section-lede.creds-lede { max-width: none; }

/* ── Index: service lines ───────────────────────── */
.line-row {
  display: grid;
  grid-template-columns: 54px minmax(200px, 0.9fr) 1.1fr;
  gap: 24px 40px;
  align-items: start;
  border-top: 1px solid var(--line);
  padding: 42px 12px 42px 24px;
  position: relative;
  text-decoration: none;
  color: inherit;
  transition: background .25s ease;
}
.line-icon { display: block; margin-top: 2px; }
.line-row:last-of-type { border-bottom: 1px solid var(--line); }
.line-row::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 100%;
  background: var(--accent);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform .3s ease;
}
.line-row:hover { background: var(--bg-soft); }
.line-row:hover::before { transform: scaleY(1); }
.line-row h3 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  letter-spacing: -0.015em;
  line-height: 1.12;
}
.line-row .tagline {
  font-family: var(--font-label);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-top: 10px;
}
.line-row .desc { color: var(--muted); font-size: 0.98rem; }
.line-row .go {
  display: inline-block;
  margin-top: 16px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform .25s ease;
}
.line-row:hover .go { transform: translateX(6px); }

/* ── Dark band (why) with seam diagonal ─────────── */
.dark-band {
  position: relative;
  background: linear-gradient(200deg, var(--primary) 0%, var(--primary-2) 100%);
  color: #fff;
  padding: calc(84px + var(--diag)) 0 84px;
  clip-path: polygon(0 var(--diag), 100% 0, 100% 100%, 0 100%);
  margin-top: 40px;
}
.dark-band::before {
  content: "";
  position: absolute;
  left: -3%;
  width: 106%;
  top: calc(var(--diag) / 2);
  height: 3px;
  background: var(--accent);
  transform: skewY(var(--skew));
}
.dark-band h2 { color: #fff; }
.dark-band .section-lede { color: #b9bec7; }
.why { display: grid; grid-template-columns: 1fr; gap: 26px; margin-top: 38px; }
.why h3 { font-family: var(--font-display); font-weight: 800; font-size: 1.12rem; margin-bottom: 8px; letter-spacing: -0.01em; }
.why p { color: #b9bec7; font-size: 0.96rem; max-width: 46ch; }

.band-split { display: grid; grid-template-columns: 1.5fr 1fr; column-gap: 56px; align-items: center; }
.band-cta {
  border-left: 1px solid rgba(255,255,255,0.14);
  padding-left: 56px;
  scroll-margin-top: 90px;
}
.band-cta h2 { color: #fff; }
.band-cta p { color: #b9bec7; max-width: 40ch; margin: 14px 0 30px; }
.cta-alt { display: block; margin-top: 16px; font-size: 0.9rem; color: #b9bec7; }
.cta-alt a { color: #fff; text-decoration: underline; }

/* About page */
.prose { max-width: 720px; }
.prose p { margin-bottom: 18px; font-size: 1.05rem; }
.prose p:last-child { margin-bottom: 0; }
.creds-row { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 30px; }
.cert-badge { display: block; width: 76px; height: 76px; }

/* ── Service detail blocks ──────────────────────── */
.svc {
  position: relative;
  display: flex;
  align-items: center;
  gap: 28px;
  border-top: 1px solid var(--line);
  padding: 36px 12px 36px 24px;
  transition: background .25s ease;
}
.svc .off-icon { flex: none; }
.svc-body { min-width: 0; }
.crosslink { margin-top: 34px; font-size: 0.95rem; color: var(--muted); }
.crosslink a { color: var(--accent); text-decoration: none; font-weight: 600; }
.crosslink a:hover { text-decoration: underline; }

/* ── Blog ──────────────────────────────────────── */
.post-list { border-top: 1px solid var(--line); }
.post-item { display: block; padding: 34px 6px; border-bottom: 1px solid var(--line); text-decoration: none; color: inherit; transition: background .2s ease; }
.post-item:hover { background: var(--bg-soft); }
.post-meta { font-family: var(--font-label); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.post-item h2 { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.3rem, 2.4vw, 1.75rem); letter-spacing: -0.015em; line-height: 1.16; margin: 10px 0; }
.post-item p { color: var(--muted); max-width: 70ch; }
.post-item .go { display: inline-block; margin-top: 12px; color: var(--accent); font-weight: 600; font-size: 0.95rem; transition: transform .25s ease; }
.post-item:hover .go { transform: translateX(6px); }

.article { max-width: 730px; margin: 0 auto; }
.article .post-meta { margin-bottom: 16px; }
.article .lead { font-size: 1.2rem; line-height: 1.55; color: var(--ink); margin-bottom: 28px; }
.article h2 { font-family: var(--font-display); font-weight: 800; font-size: 1.5rem; letter-spacing: -0.015em; line-height: 1.2; margin: 40px 0 14px; }
.article p { font-size: 1.06rem; line-height: 1.72; margin-bottom: 20px; color: var(--ink); }
.article a { color: var(--accent); text-decoration: underline; }
.article strong { font-weight: 700; }
.svc:last-of-type { border-bottom: 1px solid var(--line); }
.svc::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 100%;
  background: var(--accent);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform .3s ease;
}
.svc:hover { background: var(--bg-soft); }
.svc:hover::before { transform: scaleY(1); }
.off-icon { display: block; width: 58px; height: 58px; }
.svc h3 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.2rem, 2.2vw, 1.5rem);
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-bottom: 16px;
}
.svc p { max-width: 640px; }

/* ── CTA band ───────────────────────────────────── */
.cta-band {
  position: relative;
  background: linear-gradient(160deg, var(--primary) 0%, var(--primary-2) 100%);
  color: #fff;
  text-align: left;
  padding: calc(84px + var(--diag)) 0 92px;
  clip-path: polygon(0 var(--diag), 100% 0, 100% 100%, 0 100%);
}
.cta-band::before {
  content: "";
  position: absolute;
  left: -3%;
  width: 106%;
  top: calc(var(--diag) / 2);
  height: 3px;
  background: var(--accent);
  transform: skewY(var(--skew));
}
.cta-band h2 {
  color: #fff;
  font-size: clamp(1.9rem, 4.4vw, 3.1rem);
  max-width: 700px;
}
.cta-band p { color: #b9bec7; max-width: 540px; margin: 16px 0 34px; }

/* ── Footer ─────────────────────────────────────── */
footer {
  background: var(--primary);
  color: #7c828c;
  padding: 38px 0;
  font-size: 0.85rem;
  border-top: 1px solid #1c1d23;
}
footer .wrap { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; }
footer a { color: #b7bcc5; text-decoration: none; }
footer a:hover { color: #fff; }

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 860px) {
  .line-row { grid-template-columns: 1fr; gap: 14px; padding-left: 24px; }
  .why { grid-template-columns: 1fr; gap: 32px; }
  .band-mark { width: 220px; height: 220px; right: -40px; }
  .band-split { grid-template-columns: 1fr; row-gap: 44px; }
  .band-cta { border-left: none; padding-left: 0; border-top: 1px solid rgba(255,255,255,0.14); padding-top: 40px; }
  .svc { flex-direction: column; align-items: flex-start; gap: 16px; }
}
@media (max-width: 640px) {
  .nav { flex-wrap: wrap; row-gap: 8px; }
  .nav .logo { flex: 0 0 100%; }
  nav.links { flex: 0 0 100%; flex-wrap: wrap; gap: 4px 18px; justify-content: flex-start; }
  nav.links a { margin-left: 0; padding: 9px 0; }
  .btn-ghost { margin-left: 0; margin-top: 10px; }
  .hero { padding-top: 64px; }
  #services, #contact { scroll-margin-top: 110px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .line-row, .svc { transition: none; }
}
