/* CyLabs Engineering — cylabseng.com
   Plain CSS, no build step, no external fonts or assets.
   Palette is defined once as custom properties; dark mode swaps the tokens. */

:root {
  --ink:        #0d1418;
  --ink-soft:   #3d4a52;
  --ink-faint:  #6b7a83;
  --paper:      #ffffff;
  --paper-alt:  #f4f6f6;
  --line:       #dfe4e5;
  --accent:     #00a2bf;  /* matches the dashed orbit ring in the CyLabs logo */
  --accent-ink: #00758a;  /* darkened for text contrast on white (AA at 5.0:1) */
  --dark-bg:    #0d1418;
  --dark-fg:    #e8edee;
  --dark-faint: #93a3aa;
  --radius: 10px;
  --wrap: 1120px;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink:       #e8edee;
    --ink-soft:  #b3c0c6;
    --ink-faint: #8798a0;
    --paper:     #0d1418;
    --paper-alt: #131e23;
    --line:      #24343b;
    --accent:    #3cc0dc;
    --accent-ink:#6ad4ea;
    --dark-bg:   #080f12;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

.skip {
  position: absolute; left: -9999px;
  background: var(--accent); color: #fff; padding: 10px 16px; z-index: 100;
}
.skip:focus { left: 12px; top: 12px; }

a { color: var(--accent-ink); }

/* ─── nav ─────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 24px; }

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--ink); text-decoration: none;
  font-weight: 650; letter-spacing: -0.01em; font-size: 1.02rem;
}
.brand em { font-style: normal; font-weight: 400; color: var(--ink-faint); }
.brand-mark { width: 40px; height: 40px; flex: none; display: block; }

/* The logo is drawn with dark strokes for light backgrounds. In dark mode those
   strokes disappear against the nav, so give it a small light backdrop. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-mark {
    background: #fff;
    border-radius: 50%;
    padding: 2px;
  }
}

.nav nav { display: flex; align-items: center; gap: 22px; }
.nav nav a {
  color: var(--ink-soft); text-decoration: none; font-size: 0.93rem;
}
.nav nav a:hover { color: var(--accent-ink); }
.nav-cta {
  border: 1px solid var(--line); border-radius: 100px;
  padding: 6px 15px; color: var(--ink) !important;
}
.nav-cta:hover { border-color: var(--accent); background: var(--paper-alt); }

@media (max-width: 720px) {
  .nav nav a:not(.nav-cta) { display: none; }
}

/* ─── hero ────────────────────────────────────────────────────────── */
.hero {
  position: relative; overflow: hidden;
  background: var(--dark-bg);
  color: var(--dark-fg);
  padding: 108px 0 96px;
}
.hero-motif {
  position: absolute; inset: 0;
  color: var(--accent);
  opacity: .85;
  pointer-events: none;
}
.hero-motif svg {
  position: absolute;
  right: -14%; top: 50%; transform: translateY(-50%);
  width: 780px; height: 780px; max-width: 105%;
}
.hero-inner { position: relative; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.76rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 18px;
}
.hero h1 {
  margin: 0 0 22px;
  font-size: clamp(2.1rem, 5.2vw, 3.5rem);
  line-height: 1.08;
  letter-spacing: -0.028em;
  font-weight: 640;
  max-width: 17ch;
}
.lede { font-size: 1.13rem; line-height: 1.62; color: #c4d0d4; max-width: 62ch; margin: 0 0 20px; }
.hero-meta { font-size: 0.95rem; color: #8fa2a8; max-width: 62ch; margin: 0 0 34px; }
.hero-meta strong { color: var(--dark-fg); font-weight: 600; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.btn {
  display: inline-block; text-decoration: none; font-weight: 550; font-size: 0.97rem;
  padding: 12px 24px; border-radius: 100px; border: 1px solid transparent;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.btn-primary { background: var(--accent); color: #04191a; border-color: var(--accent); }
.btn-primary:hover { background: #008fa8; border-color: #008fa8; }
.btn-ghost { border-color: rgba(255,255,255,.26); color: var(--dark-fg); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ─── hero radar animation ────────────────────────────────────────── */
.sweep {
  transform-origin: 300px 300px;
  animation: sweep-rotate 9s linear infinite;
}
@keyframes sweep-rotate { to { transform: rotate(360deg); } }

.blip {
  opacity: 0;
  animation: blip-flash 9s linear infinite;
}
@keyframes blip-flash {
  0%   { opacity: 0; }
  2%   { opacity: .95; }
  22%  { opacity: 0; }
  100% { opacity: 0; }
}

/* ─── reveal on scroll ────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .55s ease, transform .55s cubic-bezier(.2,.7,.3,1);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .sweep { animation: none; }
  .blip  { animation: none; opacity: .55; }
  .reveal, .reveal.in {
    opacity: 1; transform: none; transition: none;
  }
}

/* ─── stats band ──────────────────────────────────────────────────── */
.stats {
  background: var(--paper-alt);
  border-bottom: 1px solid var(--line);
  padding: 40px 0;
}
.stats-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}
.stat {
  display: flex; flex-direction: column; gap: 5px;
  padding-left: 18px;
  border-left: 2px solid var(--accent);
}
.stat-n {
  font-size: clamp(1.6rem, 3.2vw, 2.15rem);
  font-weight: 660; letter-spacing: -0.03em; line-height: 1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.stat-l {
  font-size: 0.85rem; line-height: 1.4; color: var(--ink-faint);
}
@media (max-width: 760px) {
  .stats-inner { grid-template-columns: repeat(2, 1fr); gap: 24px 20px; }
  .stats { padding: 32px 0; }
}

/* ─── lifecycle band ──────────────────────────────────────────────── */
.lifecycle { padding: 70px 0; border-bottom: 1px solid var(--line); }
.lifecycle-h {
  margin: 0 0 34px;
  font-size: clamp(1.4rem, 2.7vw, 1.9rem);
  line-height: 1.24; letter-spacing: -0.022em; font-weight: 640;
  max-width: 26ch;
}
.stages {
  counter-reset: stage;
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap;
}
.stages li {
  counter-increment: stage;
  flex: 1 1 165px;
  border-top: 2px solid var(--accent);
  padding: 15px 18px 4px 0;
  font-size: 0.9rem;
  color: var(--ink);
  line-height: 1.35;
}
.stages li:nth-child(n+4) { border-top-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.stages li::before {
  content: counter(stage, decimal-leading-zero);
  display: block;
  font-family: var(--mono);
  font-size: 0.7rem; letter-spacing: 0.1em;
  color: var(--accent); margin-bottom: 7px;
}
.lifecycle-lede {
  margin: 0 0 16px; max-width: 70ch;
  color: var(--ink-soft); font-size: 1.06rem; line-height: 1.62;
}
.lifecycle-lede + .stages { margin-top: 34px; }
.lifecycle-note {
  margin: 30px 0 0; max-width: 68ch;
  color: var(--ink-soft); font-size: 1.0rem;
}
@media (max-width: 640px) {
  .lifecycle { padding: 52px 0; }
  .stages li { flex: 1 1 45%; }
}

/* ─── sections ────────────────────────────────────────────────────── */
.section { padding: 88px 0; border-bottom: 1px solid var(--line); }
.section-alt { background: var(--paper-alt); }
.section h2 {
  margin: 0 0 18px;
  font-size: clamp(1.55rem, 3.1vw, 2.15rem);
  line-height: 1.2; letter-spacing: -0.022em; font-weight: 640;
  max-width: 24ch;
}
.section-lede { font-size: 1.06rem; color: var(--ink-soft); max-width: 66ch; margin: 0 0 44px; }
.note { font-size: 0.93rem; color: var(--ink-faint); margin: 34px 0 0; }
.sub {
  font-family: var(--mono);
  font-size: 0.74rem; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--ink-faint); margin: 0 0 20px; font-weight: 500;
}

/* ─── grids ───────────────────────────────────────────────────────── */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .section { padding: 60px 0; }
  .hero { padding: 76px 0 68px; }
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.card:hover {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
  transform: translateY(-2px);
  box-shadow: 0 6px 22px -12px rgba(0,0,0,.28);
}
.card h3::before { transition: width .18s ease; }
.card:hover h3::before { width: 42px; }
@media (prefers-reduced-motion: reduce) {
  .card, .card:hover { transform: none; transition: border-color .18s ease; }
}
.card h3 {
  margin: 0 0 10px; font-size: 1.05rem; font-weight: 640; letter-spacing: -0.012em;
}
.card h3::before {
  content: ""; display: block;
  width: 26px; height: 2px; background: var(--accent);
  margin-bottom: 14px;
}
.card p { margin: 0; font-size: 0.96rem; color: var(--ink-soft); line-height: 1.62; }

.domain {
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 28px 26px;
}
.domain h3 { margin: 0 0 12px; font-size: 1.18rem; font-weight: 640; letter-spacing: -0.015em; }
.domain p { margin: 0; color: var(--ink-soft); font-size: 0.97rem; line-height: 1.62; }
.domain-proof {
  margin-top: 18px !important;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 0.78rem !important;
  line-height: 1.6 !important;
  color: var(--ink-faint) !important;
}

.engagement {
  border-left: 2px solid var(--accent);
  padding: 4px 0 4px 22px;
}
.engagement h3 { margin: 0 0 9px; font-size: 1.08rem; font-weight: 640; letter-spacing: -0.012em; }
.engagement p { margin: 0; color: var(--ink-soft); font-size: 0.97rem; }

/* ─── background ──────────────────────────────────────────────────── */
.bg-layout { display: grid; grid-template-columns: 1.35fr 1fr; gap: 56px; align-items: start; }
@media (max-width: 860px) { .bg-layout { grid-template-columns: 1fr; gap: 44px; } }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li {
  padding: 15px 0 15px 20px;
  border-left: 1px solid var(--line);
  position: relative;
}
.timeline li::before {
  content: ""; position: absolute; left: -4.5px; top: 24px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--accent);
}
.timeline li:first-child::before { background: var(--accent); }
.role { display: block; font-weight: 580; letter-spacing: -0.008em; }
.org  { display: block; font-size: 0.92rem; color: var(--ink-faint); margin-top: 2px; }

.section-alt .facts { background: var(--paper); }

.facts {
  background: var(--paper-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
}
.facts dl { margin: 0; }
.facts dt {
  font-family: var(--mono);
  font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); margin: 22px 0 7px;
}
.facts dt:first-child { margin-top: 0; }
.facts dd { margin: 0 0 6px; font-size: 0.94rem; color: var(--ink-soft); line-height: 1.55; }

/* ─── contact ─────────────────────────────────────────────────────── */
.section-dark {
  background: var(--dark-bg); color: var(--dark-fg); border-bottom: none;
}
.section-dark h2 { max-width: 22ch; }
.section-dark .section-lede { color: #b3c2c7; }
.section-dark .note { color: #7f9299; }
.contact-inner { max-width: 720px; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }

/* ─── footer ──────────────────────────────────────────────────────── */
.footer { background: var(--dark-bg); color: #6f8188; padding: 26px 0 40px; }
.footer-inner {
  display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between;
  align-items: center;
  font-size: 0.85rem; border-top: 1px solid rgba(255,255,255,.09); padding-top: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 15px; }
/* The logo is drawn with dark strokes for light backgrounds, so it needs a
   light ground to sit on inside the dark footer. Circular chip matches the mark. */
/* Sized so the arced wordmark is legible — below about 110px it turns to mush.
   The logo is drawn with dark strokes for light backgrounds, so it needs a light
   panel here. Rounded rectangle rather than a circle: the satellite breaks the
   top edge and the wordmark the bottom, so the artwork is not actually round. */
.footer-brand img {
  height: 132px; width: auto; flex: none;
  background: #fff; border-radius: 14px; padding: 10px 14px;
}
@media (max-width: 620px) {
  .footer-brand img { height: 112px; }
}
.footer-tag { color: #5d7078; }
@media (max-width: 620px) { .footer-inner { justify-content: flex-start; } }

/* ─── focus visibility ────────────────────────────────────────────── */
a:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px;
}
