/* Carrier Pigeon Tech — landing page. Palette from the rock dove. */
:root {
  --underwing: #E6E9EE;   /* page background */
  --down:      #F2F4F7;   /* lighter panel */
  --feather:   #B9C0CB;   /* rules, contours */
  --slate:     #5F6878;   /* secondary text */
  --bar:       #23262D;   /* wing-bar charcoal: text, dark band */
  --sheen-green:  #1F8A68;
  --sheen-violet: #8B3F87;
  --eye:       #E8731C;   /* the one sharp accent */

  --display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --body: "Atkinson Hyperlegible", "Trebuchet MS", sans-serif;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--underwing);
  color: var(--bar);
  font: 400 18px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 0.95; margin: 0; }
p { margin: 0; }

:focus-visible { outline: 3px solid var(--eye); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--bar); color: #fff; padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* ---------- header ---------- */
.site-header {
  max-width: var(--max); margin: 0 auto;
  padding: 20px var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  position: relative; z-index: 2;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { border-radius: 10px; }
.brand span { font: 800 26px/1 var(--display); letter-spacing: 0.01em; }
.site-header nav { display: flex; align-items: center; gap: 28px; font-size: 16px; }
.site-header nav a { text-decoration: none; }
.site-header nav a:not(.nav-cta):hover { text-decoration: underline; text-underline-offset: 4px; }
.nav-cta { white-space: nowrap; border: 2px solid var(--bar); border-radius: 999px; padding: 8px 18px; font-weight: 700; }
.nav-cta:hover { background: var(--bar); color: var(--underwing); }

/* ---------- hero: the contour map and the flight ---------- */
.hero {
  position: relative;
  max-width: var(--max); margin: 0 auto;
  padding: clamp(32px, 6vw, 72px) var(--gutter) 0;
  min-height: min(760px, 92vh);
  isolation: isolate;
}
.hero::before {           /* topographic map, faded toward the copy */
  content: ""; position: absolute; z-index: -1;
  inset: -90px calc(50% - 50vw) 0;
  background: url("assets/contours.svg") center / cover no-repeat;
  -webkit-mask-image: linear-gradient(100deg, transparent 8%, #000 55%), linear-gradient(180deg, #000 70%, transparent);
  -webkit-mask-composite: source-in;
          mask-image: linear-gradient(100deg, transparent 8%, #000 55%), linear-gradient(180deg, #000 70%, transparent);
          mask-composite: intersect;
}
.hero-copy { position: relative; z-index: 1; max-width: 640px; }
h1 {
  font-weight: 900;
  font-size: clamp(64px, 11vw, 152px);
  letter-spacing: -0.01em;
  line-height: 0.86;
}
h1 .line { display: block; animation: rise 0.9s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(var(--d) * 140ms + 100ms); }
.lede { margin-top: 28px; font-size: 21px; max-width: 34em; color: var(--bar); }
.hero-actions { margin-top: 36px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.lede, .hero-actions { animation: rise 0.9s cubic-bezier(.2, .7, .2, 1) 420ms both; }

.button {
  display: inline-block; text-decoration: none;
  background: var(--eye); color: var(--bar);
  font-weight: 700; font-size: 18px;
  padding: 14px 26px; border-radius: 999px;
  box-shadow: 0 2px 0 var(--bar);
  transition: transform .15s ease, box-shadow .15s ease;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 4px 0 var(--bar); }
.button:active { transform: translateY(1px); box-shadow: 0 1px 0 var(--bar); }
.text-link { font-weight: 700; text-underline-offset: 5px; text-decoration-thickness: 2px; text-decoration-color: var(--sheen-green); }

.route { position: absolute; inset: 40px 0 0; width: 100%; height: calc(100% - 40px); z-index: 0; }
.route text { font: 700 20px var(--body); fill: var(--bar); paint-order: stroke; stroke: var(--underwing); stroke-width: 6px; stroke-linejoin: round; }
.reveal-path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.9s cubic-bezier(.45, 0, .2, 1) 0.35s forwards; }
.pin-end { animation: land .5s ease-out 3.1s both; transform-origin: 1110px 120px; }

@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes land { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: none; } }

/* ---------- sections ---------- */
.process, .build, .why {
  max-width: var(--max); margin: 0 auto;
  padding: clamp(72px, 10vw, 128px) var(--gutter) 0;
}
h2 { font-weight: 800; font-size: clamp(44px, 6vw, 72px); }
h3 { font-weight: 800; font-size: 36px; }

.section-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 64px; align-items: end; }
.section-head p { color: var(--slate); max-width: 30em; }

/* the four legs share one dotted route line */
.legs {
  list-style: none; margin: 56px 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px;
  counter-reset: leg;
  position: relative;
}
.legs::before {
  content: ""; position: absolute; left: 22px; right: 0; top: 22px;
  border-top: 4px dotted var(--feather);
}
.legs li { position: relative; counter-increment: leg; padding-top: 72px; }
.legs li::before {
  content: counter(leg);
  position: absolute; top: 0; left: 0;
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--underwing); border: 3px solid var(--bar);
  font: 800 24px/1 var(--display);
}
.legs li:last-child::before { background: var(--eye); border-color: var(--eye); }
.legs .span { color: var(--slate); font-size: 16px; margin: 6px 0 12px; }

.build-grid { margin-top: 48px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.build-grid > div { border-top: 3px solid var(--bar); padding-top: 20px; }
.build-grid h3 { font-size: 32px; margin-bottom: 12px; }
.build-grid p { color: var(--slate); max-width: 26em; }

.why { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 32px 64px; align-items: end; }
.why-quote { font-weight: 600; font-size: clamp(36px, 4.6vw, 60px); line-height: 1.02; max-width: 16em; }
.why p { color: var(--slate); max-width: 28em; }

/* ---------- contact: the dark wing-bar band with a neck-sheen glow ---------- */
.contact {
  margin-top: clamp(80px, 11vw, 144px);
  background:
    radial-gradient(60% 90% at 100% 0%, rgba(31, 138, 104, .45), transparent 60%),
    radial-gradient(45% 70% at 88% 100%, rgba(139, 63, 135, .40), transparent 65%),
    var(--bar);
  color: var(--down);
}
.contact-inner { max-width: var(--max); margin: 0 auto; padding: clamp(64px, 9vw, 112px) var(--gutter); }
.contact h2 { font-size: clamp(52px, 8vw, 104px); max-width: 9em; }
.contact p { margin: 24px 0 36px; max-width: 32em; font-size: 20px; color: #C9CFD8; }
.contact .button { box-shadow: 0 2px 0 #000; }

.site-footer {
  background: var(--bar); color: #9AA2B1; font-size: 15px;
  border-top: 1px solid #3A3F49;
  padding: 20px var(--gutter);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px;
}

/* ---------- small screens ---------- */
@media (max-width: 860px) {
  .site-header nav a:not(.nav-cta) { display: none; }
  .hero { min-height: 0; padding-bottom: 8px; }
  .hero::before { -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 55%, transparent); mask-image: linear-gradient(180deg, transparent 0%, #000 55%, transparent); }
  .route { position: relative; inset: auto; height: auto; margin-top: 24px; }
  .route text { font-size: 26px; }
  #flightpath { stroke-width: 9; stroke-dasharray: 0 22; }
  .section-head, .why { grid-template-columns: 1fr; }
  .legs { grid-template-columns: 1fr; gap: 32px; }
  .legs::before { top: 22px; bottom: 0; left: 22px; right: auto; border-top: 0; border-left: 4px dotted var(--feather); }
  .legs li { padding: 0 0 0 76px; }
  .build-grid { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 420px) {
  .brand span { font-size: 22px; }
  .nav-cta { padding: 6px 14px; font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal-path { stroke-dashoffset: 0; }
}
