/* Synapse Venture — public pages. Depends on base.css.
 *
 * Direction: an engineering drawing. Hairline rules, a plotted dot ground,
 * monospace annotations, and one live signal network in the hero. The accent
 * is the only saturated thing on the page; everything else is drawn, not filled.
 */

:root {
  --dot:  rgba(16, 18, 26, .085);
  --rule: rgba(16, 18, 26, .10);
}
:root[data-theme="dark"] {
  --dot:  rgba(200, 214, 255, .10);
  --rule: rgba(200, 214, 255, .13);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --dot:  rgba(200, 214, 255, .10);
    --rule: rgba(200, 214, 255, .13);
  }
}

/* ---------- schematic building blocks ---------- */

/* plotted ground, used behind the hero and the closing band */
.ground {
  background-image: radial-gradient(circle at 1px 1px, var(--dot) 1px, transparent 0);
  background-size: 24px 24px;
}

/* a hairline with a tick, used to open sections */
.tick {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--mono);
  font-size: .72rem; font-weight: 600; letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent);
}
.tick::before {
  content: ""; width: 26px; height: 1px; background: currentColor; opacity: .55;
}

/* corner ticks, like registration marks on a drawing */
.marks { position: relative; }
.marks::before, .marks::after {
  content: ""; position: absolute; width: 13px; height: 13px;
  border: 1px solid var(--accent); opacity: .45; pointer-events: none;
}
.marks::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.marks::after { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.site-head.stuck { border-bottom-color: var(--line); }
.site-head .inner { display: flex; align-items: center; gap: 1rem; height: 68px; }

.site-nav { display: flex; align-items: center; gap: .3rem; }
.site-nav a:not(.btn) {
  position: relative;
  padding: .45rem .8rem;
  font-size: .9rem; font-weight: 500;
  color: var(--ink-2);
  border-radius: 999px;
  transition: color .16s ease;
}
.site-nav a:not(.btn)::after {
  content: ""; position: absolute; left: .8rem; right: .8rem; bottom: .25rem;
  height: 1px; background: var(--accent);
  transform: scaleX(0); transform-origin: left;
  transition: transform .22s cubic-bezier(.2, .8, .3, 1);
}
.site-nav a:not(.btn):hover { color: var(--ink); }
.site-nav a:not(.btn):hover::after { transform: scaleX(1); }
.nav-toggle { display: none; }

@media (max-width: 860px) {
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: .15rem;
    padding: .7rem 1.25rem 1.15rem;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .site-nav[data-open="false"] { display: none; }
  .site-nav a:not(.btn) { padding: .65rem .75rem; border-radius: var(--radius-sm); }
  .site-nav a:not(.btn)::after { display: none; }
  .site-nav .btn { margin-top: .5rem; }
  .nav-toggle { display: inline-flex; }
}

/* ---------- section rhythm ---------- */
.section { padding: clamp(3.5rem, 2rem + 7vw, 7rem) 0; }
.section.tight { padding-block: clamp(2.5rem, 1.5rem + 4vw, 4.5rem); }
.section-head { max-width: 660px; margin-bottom: clamp(2rem, 1.2rem + 2.5vw, 3.4rem); }
.section-head .tick { margin-bottom: 1rem; }
.section-head h2 { text-wrap: balance; }
.section-head p { margin-top: 1rem; }
.alt { background: var(--bg-deep); border-block: 1px solid var(--line-soft); }

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: clamp(3rem, 2rem + 7vw, 6.5rem) 0 clamp(3rem, 2rem + 5vw, 5.5rem);
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background-image: radial-gradient(circle at 1px 1px, var(--dot) 1px, transparent 0);
  background-size: 24px 24px;
  -webkit-mask-image: radial-gradient(120% 82% at 50% 0%, #000 35%, transparent 78%);
  mask-image: radial-gradient(120% 82% at 50% 0%, #000 35%, transparent 78%);
}
.hero::after {
  content: ""; position: absolute; inset: -35% -12% auto; z-index: -1;
  height: 640px; pointer-events: none;
  background:
    radial-gradient(42% 50% at 20% 36%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%),
    radial-gradient(36% 44% at 80% 18%, color-mix(in srgb, var(--cyan) 17%, transparent), transparent 68%);
  filter: blur(26px);
}

.hero-grid {
  display: grid; gap: clamp(2.2rem, 1rem + 4vw, 4rem);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
}
@media (max-width: 940px) { .hero-grid { grid-template-columns: 1fr; } }

.hero h1 { margin-block: 1.1rem .1rem; text-wrap: balance; }
.hero .lede { margin-top: 1.2rem; max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 2rem; }

.pill {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .32rem .85rem .32rem .8rem;
  font-family: var(--mono);
  font-size: .74rem; font-weight: 500; letter-spacing: .04em;
  color: var(--ink-2);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
}
.pill .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 20%, transparent);
}

/* three plain facts, set like a spec table */
.hero-meta {
  display: grid; gap: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 2.6rem;
  border-top: 1px solid var(--rule);
}
@media (max-width: 480px) { .hero-meta { grid-template-columns: 1fr 1fr; } }
.hero-meta div {
  padding: 1rem 1.1rem 0 0;
  border-right: 1px solid var(--rule);
}
.hero-meta div:last-child { border-right: 0; }
.hero-meta div + div { padding-left: 1.1rem; }
.hero-meta strong {
  display: block;
  font-family: var(--mono);
  font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--accent);
}
.hero-meta span {
  display: block; margin-top: .35rem;
  font-size: .84rem; line-height: 1.45; color: var(--ink-2);
}

/* the signal network panel */
.hero-art {
  position: relative;
  aspect-ratio: 1 / .88;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.hero-art canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hero-art .label {
  position: absolute; left: 1rem; top: .9rem;
  display: flex; align-items: center; gap: .45rem;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3);
}
.hero-art .label .led {
  width: 6px; height: 6px; border-radius: 50%; background: var(--cyan);
  animation: blink 2.6s ease-in-out infinite;
}
@keyframes blink { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
.hero-art .chip {
  position: absolute; left: 50%; bottom: 1rem; transform: translateX(-50%);
  padding: .48rem .95rem;
  font-family: var(--mono); font-size: .72rem; white-space: nowrap;
  color: var(--ink-2);
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(8px);
}
@media (max-width: 940px) { .hero-art { aspect-ratio: 3 / 2; } }

/* ---------- capability strip ---------- */
.strip {
  position: relative;
  border-block: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.strip-track {
  display: flex; width: max-content;
  animation: slide 46s linear infinite;
}
.strip:hover .strip-track { animation-play-state: paused; }
.strip-run { display: flex; align-items: center; }
.strip-run span {
  display: flex; align-items: center; gap: 1.6rem;
  padding: .85rem 1.6rem .85rem 0;
  font-family: var(--mono); font-size: .78rem; letter-spacing: .03em;
  color: var(--ink-3); white-space: nowrap;
}
.strip-run span::after {
  content: ""; width: 4px; height: 4px; border-radius: 50%;
  background: var(--accent); opacity: .5;
}
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .strip { overflow-x: auto; }
  .strip-track { animation: none; }
}

/* ---------- service cards ---------- */
.cards { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(266px, 1fr)); }

.feature {
  position: relative;
  display: flex; flex-direction: column;
  padding: 1.5rem 1.4rem 1.6rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform .22s ease, box-shadow .26s ease, border-color .22s ease;
}
.feature::after {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--cyan));
  transform: scaleX(0); transform-origin: left;
  transition: transform .3s cubic-bezier(.2, .8, .3, 1);
}
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--accent-line); }
.feature:hover::after { transform: scaleX(1); }

/* the drawn illustration at the top of each card */
.plate {
  position: relative;
  height: 116px; margin: -.35rem -.35rem 1.15rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  background:
    radial-gradient(circle at 1px 1px, var(--dot) 1px, transparent 0) 0 0 / 16px 16px,
    var(--surface-2);
  display: grid; place-items: center;
  overflow: hidden;
}
.plate svg { width: 148px; height: 88px; overflow: visible; }
.plate .ln { fill: none; stroke: var(--ink-3); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.plate .hi { fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.plate .fill { fill: var(--accent); opacity: .16; }
.plate .fill-hi { fill: var(--accent); }
.plate .dashed { stroke-dasharray: 4 4; }

/* the one animated detail per card, on hover */
.feature:hover .plate .travel { animation: travel 1.5s ease-in-out infinite; }
@keyframes travel { 0% { stroke-dashoffset: 44; } 100% { stroke-dashoffset: 0; } }

.feature h3 { margin-bottom: .5rem; }
.feature > p { color: var(--ink-2); font-size: .93rem; }
.feature ul {
  margin: 1rem 0 0; padding: .9rem 0 0; list-style: none;
  display: grid; gap: .45rem;
  font-size: .84rem; color: var(--ink-3);
  border-top: 1px solid var(--line-soft);
}
.feature li { display: flex; gap: .55rem; align-items: flex-start; }
.feature li::before {
  content: ""; flex: none; margin-top: .48rem;
  width: 5px; height: 5px; border: 1px solid var(--accent); border-radius: 1px;
  transform: rotate(45deg);
}

/* ---------- process ---------- */
.steps {
  position: relative;
  display: grid; gap: 1.1rem;
  grid-template-columns: repeat(auto-fit, minmax(212px, 1fr));
}
/* the wire the steps sit on */
.steps::before {
  content: ""; position: absolute; left: 0; right: 0; top: 34px; height: 1px;
  background: repeating-linear-gradient(90deg, var(--rule) 0 7px, transparent 7px 14px);
}
@media (max-width: 700px) { .steps::before { display: none; } }

.step {
  position: relative;
  padding: 1.4rem 1.3rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  counter-increment: step;
  transition: transform .2s ease, border-color .2s ease, box-shadow .22s ease;
}
.steps { counter-reset: step; }
.step::before {
  content: "0" counter(step);
  display: inline-grid; place-items: center;
  width: 34px; height: 34px; margin-bottom: 1rem;
  font-family: var(--mono); font-size: .74rem; font-weight: 700;
  color: var(--accent);
  background: var(--surface);
  border: 1px solid var(--accent-line);
  border-radius: 50%;
}
.step:hover { transform: translateY(-3px); border-color: var(--accent-line); box-shadow: var(--shadow-sm); }
.step h3 { margin-bottom: .4rem; font-size: 1rem; }
.step p { font-size: .89rem; color: var(--ink-2); }

/* ---------- approach ---------- */
/* Two across, not four: these cards pair a glyph with a paragraph, so a
   quarter-width column left the text about twenty characters wide. */
/* A fixed 2x2 rather than auto-fit: three across left a single orphan card
   on the second row, and the text column needs the width regardless. */
#approach .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 760px) { #approach .cards { grid-template-columns: 1fr; } }

.principle {
  position: relative;
  display: flex; gap: 1rem; align-items: flex-start;
  padding: 1.4rem 1.35rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .2s ease, border-color .2s ease, box-shadow .22s ease;
}
.principle:hover { transform: translateY(-3px); border-color: var(--accent-line); box-shadow: var(--shadow-sm); }
.principle .glyph {
  flex: none; width: 46px; height: 46px;
  display: grid; place-items: center;
  border: 1px solid var(--accent-line);
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
}
.principle .glyph svg { width: 22px; height: 22px; }
.principle h3 { font-size: 1rem; margin-bottom: .35rem; }
.principle p { font-size: .89rem; color: var(--ink-2); }
.principle ul {
  margin: .8rem 0 0; padding: 0; list-style: none;
  display: flex; flex-wrap: wrap; gap: .35rem;
}
.principle li {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .02em;
  color: var(--ink-3);
  padding: .15rem .5rem;
  border: 1px solid var(--line);
  border-radius: 999px;
}

/* ---------- closing band ---------- */
.cta-band {
  position: relative; overflow: hidden;
  padding: clamp(2.4rem, 1.5rem + 4vw, 4rem);
  border-radius: var(--radius-lg);
  /* fixed, not themed: white has to stay legible on it in both palettes */
  background: linear-gradient(125deg, #4f46e5, #0e7490);
  color: #fff;
  box-shadow: var(--shadow-lg);
}
.cta-band .circuit {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none; opacity: .5;
}
.cta-band .circuit path { fill: none; stroke: rgba(255, 255, 255, .5); stroke-width: 1; }
.cta-band .circuit circle { fill: rgba(255, 255, 255, .85); }
.cta-band .inner { position: relative; }
.cta-band h2 { color: #fff; max-width: 18ch; text-wrap: balance; }
.cta-band p { margin-top: .9rem; max-width: 50ch; color: rgba(255, 255, 255, .9); }
.cta-band .btn {
  margin-top: 1.8rem;
  --btn-bg: #fff; --btn-ink: #14162b; --btn-line: #fff;
}
.cta-band .btn:hover { filter: brightness(.95); }

/* ---------- contact ---------- */
.contact-grid {
  display: grid; gap: clamp(1.6rem, 1rem + 3vw, 3rem);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
}
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-list { display: grid; gap: .7rem; margin-top: 1.8rem; }
.contact-list a, .contact-list div {
  display: flex; align-items: center; gap: .85rem;
  padding: .95rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: .93rem;
  transition: border-color .18s ease, transform .18s ease;
}
.contact-list a:hover { border-color: var(--accent); transform: translateX(3px); }
.contact-list .ico { color: var(--accent); display: grid; place-items: center; }
.contact-list .ico svg { width: 18px; height: 18px; }
.contact-list span.k {
  display: block;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: .1rem;
}

/* ---------- footer ---------- */
.site-foot {
  padding: 3rem 0 2.2rem;
  border-top: 1px solid var(--line);
  background: var(--bg-deep);
}
.foot-top { display: flex; flex-wrap: wrap; gap: 1.8rem; align-items: flex-start; }
.foot-links { display: flex; flex-wrap: wrap; gap: 1.3rem; font-size: .88rem; }
.foot-links a { color: var(--ink-2); }
.foot-links a:hover { color: var(--accent); }
.foot-bar {
  display: flex; flex-wrap: wrap; gap: .75rem; align-items: center;
  margin-top: 2.2rem; padding-top: 1.3rem;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: .74rem; letter-spacing: .03em; color: var(--ink-3);
}

/* ---------- scroll reveal ---------- */
.reveal {
  opacity: 0; transform: translateY(16px);
  transition: opacity .65s ease, transform .65s cubic-bezier(.2, .8, .3, 1);
}
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }
