/* ==========================================================================
   Side Quest Innovations — site stylesheet
   Shared by every marketing page (home.html, and future pages).
   Palette is derived from the SQI mark: near-black field, electric blue on
   the left hemisphere, burnt orange / amber on the right, chrome wordmark.
   ========================================================================== */

/* ---------- 1. Tokens ---------------------------------------------------- */
:root {
  /* surfaces */
  --bg:          #04070b;
  --bg-2:        #070c14;
  --bg-3:        #0a111c;
  --panel:       rgba(11, 19, 31, 0.62);
  --panel-solid: #0b131f;
  --line:        rgba(126, 172, 255, 0.14);
  --line-strong: rgba(126, 172, 255, 0.28);

  /* ink */
  --ink:    #e9eff8;
  --ink-2:  #a3b4cc;
  --ink-3:  #6c7d95;

  /* brand */
  --blue:   #2b8cff;
  --blue-d: #1257c4;
  --cyan:   #4fd8ff;
  --orange: #ff7a1a;
  --amber:  #ffb02e;
  --burnt:  #c26213;

  /* effects */
  --grad-brand: linear-gradient(100deg, var(--cyan) 0%, var(--blue) 32%, var(--orange) 74%, var(--amber) 100%);
  --grad-chrome: linear-gradient(180deg, #ffffff 0%, #c8d4e4 42%, #7d8ea6 58%, #eef3fa 100%);
  --glow-blue:  0 0 40px rgba(43, 140, 255, 0.35);
  --glow-amber: 0 0 40px rgba(255, 122, 26, 0.30);

  /* type */
  --font-display: 'Space Grotesk', 'Segoe UI', system-ui, sans-serif;
  --font-body:    'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-brand:   'Orbitron', 'Space Grotesk', sans-serif;

  /* metrics */
  --nav-h: 74px;
  --maxw: 1240px;
  --gutter: clamp(20px, 4vw, 48px);
  --r-sm: 10px;
  --r:    16px;
  --r-lg: 24px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- 2. Reset / base --------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

::selection { background: rgba(255, 122, 26, 0.35); color: #fff; }

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  padding: 12px 20px;
  background: var(--orange);
  color: #0a0500;
  font-weight: 700;
  border-radius: 0 0 var(--r-sm) 0;
}
.skip-link:focus { left: 0; }

/* ---------- 3. Layout primitives ---------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding: clamp(72px, 10vw, 132px) 0;
}
.section--tight { padding: clamp(48px, 6vw, 80px) 0; }

/* thin brand rule between major sections */
.section + .section::before {
  content: "";
  position: absolute;
  inset-inline: var(--gutter);
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong) 20%, var(--line-strong) 80%, transparent);
  opacity: 0.6;
}

/* ---------- 4. Type ------------------------------------------------------ */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.025em;
  margin: 0;
  text-wrap: balance;
}

h1 { font-size: clamp(2.4rem, 6.2vw, 4.5rem); }
h2 { font-size: clamp(1.9rem, 3.9vw, 3rem); }
h3 { font-size: clamp(1.15rem, 1.7vw, 1.45rem); letter-spacing: -0.015em; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: clamp(1.03rem, 1.35vw, 1.2rem);
  color: var(--ink-2);
  line-height: 1.72;
  max-width: 62ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-brand);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: var(--grad-brand);
}
.eyebrow--amber { color: var(--amber); }

.grad-text {
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.muted { color: var(--ink-2); }
.dim   { color: var(--ink-3); }

.section-head { max-width: 780px; margin-bottom: clamp(36px, 5vw, 60px); }
.section-head .lede { margin-top: 20px; }

/* ---------- 5. Buttons --------------------------------------------------- */
.btn {
  --btn-bg: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 24px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 0.94rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
  border: 1px solid var(--line-strong);
  background: var(--btn-bg);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease),
              border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  position: relative;
  border-color: transparent;
  color: #120800;
  background: linear-gradient(100deg, var(--amber), var(--orange) 55%, var(--burnt));
  box-shadow: 0 8px 26px -10px rgba(255, 122, 26, 0.75);
}
.btn--primary:hover { box-shadow: 0 14px 38px -12px rgba(255, 122, 26, 0.9); }

.btn--ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(8px);
}
.btn--ghost:hover {
  border-color: rgba(79, 216, 255, 0.5);
  background: rgba(43, 140, 255, 0.1);
}

.btn--sm { padding: 9px 18px; font-size: 0.84rem; }

.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(3px); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--amber);
  border-bottom: 1px solid rgba(255, 176, 46, 0.3);
  padding-bottom: 2px;
  transition: gap 0.25s var(--ease), border-color 0.25s var(--ease);
}
.link-arrow:hover { gap: 14px; border-color: var(--amber); }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

/* ---------- 6. Header / nav ---------------------------------------------
   NOTE: nav link list is intentionally simple — add <li> items to .nav-list
   (and the matching entry in js/site.js NAV_PAGES) as new pages are built.
   ------------------------------------------------------------------------ */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background-color 0.35s var(--ease), border-color 0.35s var(--ease),
              backdrop-filter 0.35s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.is-stuck {
  background: rgba(4, 7, 11, 0.82);
  backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: var(--line);
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
  width: 100%;
}

/* brand lockup */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  margin-right: auto;
}
.brand__mark {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  object-fit: cover;
  background: radial-gradient(circle at 30% 30%, rgba(43,140,255,.5), transparent 60%),
              radial-gradient(circle at 70% 70%, rgba(255,122,26,.5), transparent 60%),
              #060b12;
  border: 1px solid var(--line);
  box-shadow: 0 0 22px -6px rgba(43, 140, 255, 0.5);
}
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name {
  font-family: var(--font-brand);
  font-size: 0.83rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  background: var(--grad-chrome);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.brand__tag {
  margin-top: 5px;
  font-family: var(--font-brand);
  font-size: 0.5rem;
  letter-spacing: 0.28em;
  color: var(--ink-3);
}

/* links */
.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-list a {
  position: relative;
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: color 0.2s var(--ease), background-color 0.2s var(--ease);
}
.nav-list a:hover { color: var(--ink); background: rgba(255, 255, 255, 0.05); }
.nav-list a[aria-current="page"] { color: var(--ink); }
/* The brand underline marks the page you are on, so it must not be gated on
   :hover — the mobile override further down assumes it is always present. */
.nav-list a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: var(--grad-brand);
}
/* pages that don't exist yet render as "coming soon" without breaking layout */
.nav-list a[data-soon]:hover::before {
  content: "soon";
  position: absolute;
  top: -2px;
  right: 2px;
  font-size: 0.52rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}

.nav-cta { flex-shrink: 0; }

/* the in-list CTA is the mobile-drawer twin of .nav-cta — one or the other */
.nav-list__cta { display: none; }

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  position: relative;
  transition: background-color 0.2s var(--ease);
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s var(--ease);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after  { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after  { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 940px) {
  .nav-toggle { display: inline-flex; }
  .nav-cta { display: none; }
  .nav-list {
    position: fixed;
    inset: var(--nav-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 18px var(--gutter) 30px;
    background: rgba(6, 10, 17, 0.97);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--line);
    transform: translateY(-14px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.35s var(--ease), opacity 0.3s var(--ease), visibility 0.3s;
  }
  .nav-list.is-open { transform: none; opacity: 1; visibility: visible; }
  .nav-list a { padding: 13px 12px; font-size: 1.02rem; }
  .nav-list a[aria-current="page"]::after { left: 12px; right: auto; width: 22px; bottom: 8px; }
  .nav-list .nav-list__cta { display: block; margin-top: 14px; }
  .nav-list .nav-list__cta .btn { width: 100%; }
}

/* ---------- 7. Hero ------------------------------------------------------ */
.hero {
  position: relative;
  min-height: min(100svh, 900px);
  display: flex;
  align-items: center;
  padding-top: calc(var(--nav-h) + 40px);
  padding-bottom: 60px;
  overflow: hidden;
  isolation: isolate;
}

/* Vanta mounts here. The gradient underneath is the no-JS / no-WebGL look. */
#vanta-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  background:
    radial-gradient(1100px 620px at 18% 8%,  rgba(43, 140, 255, 0.22), transparent 62%),
    radial-gradient(900px 560px at 88% 78%, rgba(255, 122, 26, 0.20), transparent 62%),
    var(--bg);
}

/* faint technical grid, echoes the mark's coordinate field */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image:
    linear-gradient(rgba(126, 172, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 172, 255, 0.055) 1px, transparent 1px);
  background-size: 76px 76px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 40%, #000 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 40%, #000 30%, transparent 100%);
  pointer-events: none;
}

/* vignette so hero copy always wins over the animation */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(4,7,11,.72) 0%, rgba(4,7,11,.34) 32%, rgba(4,7,11,.86) 100%),
    radial-gradient(ellipse 70% 60% at 30% 50%, rgba(4,7,11,.6), transparent 70%);
  pointer-events: none;
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
  width: 100%;
}

.hero h1 { margin-bottom: 24px; }
.hero h1 .line { display: block; }

.hero__lede { font-size: clamp(1.05rem, 1.45vw, 1.24rem); max-width: 56ch; }

/* stat strip beneath the hero copy */
/* Separators are drawn as inset shadows on each cell rather than as gaps over
   a tinted background — a partly-filled last row must not leave colour blocks. */
.hero__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  margin-top: 52px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  background: rgba(7, 12, 20, 0.72);
  backdrop-filter: blur(10px);
}
.hero__stat {
  padding: 18px 20px;
  box-shadow: inset -1px -1px 0 var(--line);
}
.hero__stat b {
  display: block;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero__stat span {
  display: block;
  margin-top: 4px;
  font-size: 0.74rem;
  line-height: 1.4;
  letter-spacing: 0.04em;
  color: var(--ink-3);
}

/* hero art — the stacked cortical planes (still used by neurodesy.html) and,
   on the home page, the live globe-in-cube mark. Both share this wrapper for
   grid placement and the small-screen reordering further down. */
.hero__art {
  position: relative;
  display: grid;
  place-items: center;
}
.hero__art svg { width: 100%; height: auto; max-width: 520px; overflow: visible; }
.hero__art::before {
  content: "";
  position: absolute;
  width: 78%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(43,140,255,.20), rgba(255,122,26,.13) 55%, transparent 72%);
  filter: blur(30px);
}
/* The stacked-planes art and its two animations left this file: they are
   assets/sqi-cortex-stack/, a component with its own stylesheet. Nothing on the
   site uses it today — the home page shows a product screenshot in that panel —
   but it is a drop-in wherever it is wanted next. */

/* Globe-in-cube variant (home page). The component ships its own bloom in
   assets/sqi-globe-mark/sqi-globe-mark.css, so the wrapper's glow would just
   double it up. Everything else about .hero__art still applies. */
.hero__art--mark::before { content: none; }
.hero__art--mark .sqi-globe-mark { max-width: 560px; }

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-family: var(--font-brand);
  font-size: 0.54rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.scroll-cue i {
  width: 1px;
  height: 42px;
  background: linear-gradient(180deg, var(--cyan), transparent);
  animation: cueDrop 2.4s ease-in-out infinite;
}
@keyframes cueDrop {
  0%, 100% { opacity: 0.25; transform: scaleY(0.5); transform-origin: top; }
  50%      { opacity: 1;    transform: scaleY(1);   transform-origin: top; }
}

@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { order: -1; max-width: 380px; margin-inline: auto; }
  .scroll-cue { display: none; }
}

/* ---------- 7b. Interior page header -------------------------------------
   Same Vanta canvas and grid/vignette treatment as the home hero, but sized
   as a masthead rather than a full viewport. Use on every page except home:
     <section class="hero hero--page"> … <div class="page-head"> … </div>
   ------------------------------------------------------------------------ */
.hero--page {
  min-height: 0;
  padding-top: calc(var(--nav-h) + clamp(58px, 8vw, 108px));
  padding-bottom: clamp(52px, 7vw, 96px);
}
.page-head { max-width: 900px; }
.page-head h1 {
  font-size: clamp(2.1rem, 5vw, 3.7rem);
  margin-bottom: 22px;
}
.page-head .lede { max-width: 66ch; }

/* ---------- 8. Marquee / capability ticker ------------------------------- */
.ticker {
  border-block: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(10,17,28,.9), rgba(4,7,11,.9));
  overflow: hidden;
  padding: 15px 0;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.ticker__track {
  display: flex;
  width: max-content;
  gap: 44px;
  animation: tickerScroll 42s linear infinite;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-brand);
  font-size: 0.67rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}
.ticker__item::after {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 8px var(--orange);
}
@keyframes tickerScroll { to { transform: translateX(-50%); } }

/* ---------- 9. Cards / tiles --------------------------------------------- */
.card {
  position: relative;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background:
    linear-gradient(158deg, rgba(20, 32, 50, 0.55), rgba(7, 12, 20, 0.55));
  backdrop-filter: blur(10px);
  overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease),
              box-shadow 0.4s var(--ease);
}
/* pointer-tracked sheen (coords set in js/site.js) */
.card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 0%),
              rgba(79, 216, 255, 0.13), transparent 62%);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
  pointer-events: none;
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: 0 24px 60px -34px rgba(0, 0, 0, 0.9);
}
.card:hover::before { opacity: 1; }

.card h3 { margin-bottom: 10px; }
.card p { font-size: 0.94rem; color: var(--ink-2); line-height: 1.62; }

.card__num {
  font-family: var(--font-brand);
  font-size: 0.6rem;
  letter-spacing: 0.24em;
  color: var(--ink-3);
  margin-bottom: 16px;
}

.card__icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  margin-bottom: 18px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(150deg, rgba(43,140,255,.20), rgba(255,122,26,.14));
  color: var(--cyan);
}
.card--amber .card__icon,
.card__icon.card--amber { color: var(--amber); }

/* bento */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}
.bento > * { grid-column: span 2; }
.bento .span-3 { grid-column: span 3; }
.bento .span-4 { grid-column: span 4; }
.bento .span-6 { grid-column: span 6; }

@media (max-width: 980px) {
  .bento { grid-template-columns: repeat(4, 1fr); }
  .bento > *, .bento .span-3, .bento .span-4 { grid-column: span 2; }
  .bento .span-6 { grid-column: span 4; }
}
@media (max-width: 620px) {
  .bento { grid-template-columns: 1fr; }
  .bento > *, .bento .span-3, .bento .span-4, .bento .span-6 { grid-column: span 1; }
}

/* generic responsive grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 16px;
}

/* ---------- 10. Split feature blocks -------------------------------------
   MEDIA SHAPE — the panels are square and the artwork fills them corner to
   corner. Every source image is already 1:1 (sqi_logo_main and Neurodesy_Logo
   are 1254 square, mpfacemesh is 3277 square), so `object-fit: cover` inside
   a 1:1 box fills completely without cropping anything away.

   Width comes from the grid column and height follows from `aspect-ratio`,
   so the panel rescales continuously with the viewport — no fixed pixel cap,
   no media query, no JS. That is what makes it behave on phones, where the
   columns collapse to one and the square goes full-bleed.

   This is the "fixed-size floating panel" branch the previous note described:
   `align-items: center` plus `aspect-ratio` on .split__media, replacing the
   old stretch-to-the-text-column behaviour and its --media-min-h floor.
   ------------------------------------------------------------------------ */
.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: clamp(32px, 5vw, 68px);
  align-items: center;
}

.split--flip .split__media { order: -1; }
@media (max-width: 820px) {
  .split--flip .split__media { order: 0; }
  /* Once the columns stack, the square would otherwise take the full content
     width — about 690px tall on a tablet, which is more screen than a support
     image deserves. Cap the width and let aspect-ratio bring the height down
     with it; phones are under this figure anyway, so they are unaffected. */
  .split__media {
    width: 100%;
    max-width: 520px;
    margin-inline: auto;
  }
}

.split__media {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  background: linear-gradient(160deg, #0c1420, #05090f);
  display: grid;
  place-items: center;
}
/* Pinned to the panel box so the artwork's own intrinsic size never gets a
   vote. Inline SVG is covered by the same rule rather than by a max-width,
   which is what used to strand it at 380px inside a much larger panel. */
.split__media img,
.split__media svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* corner brackets — HUD detail */
.split__media::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(126, 172, 255, 0.16);
  border-radius: var(--r);
  pointer-events: none;
  mask-image: linear-gradient(0deg, #000 0 22%, transparent 22% 78%, #000 78% 100%),
              linear-gradient(90deg, #000 0 22%, transparent 22% 78%, #000 78% 100%);
  -webkit-mask-image: linear-gradient(0deg, #000 0 22%, transparent 22% 78%, #000 78% 100%),
                      linear-gradient(90deg, #000 0 22%, transparent 22% 78%, #000 78% 100%);
  -webkit-mask-composite: source-over;
  mask-composite: add;
}
/* Technical line-art shot on a light background: invert it so the wireframe
   reads as light-on-dark, then tint it back toward the brand blue. */
.split__media--invert { background: #05090f; }
.split__media--invert img {
  filter: invert(1) hue-rotate(180deg) saturate(0.4) brightness(0.82) contrast(1.15);
  object-fit: cover;
  opacity: 0.92;
}
.split__media--invert::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(ellipse 70% 70% at 50% 45%, transparent 30%, rgba(4,7,11,.85) 100%),
              linear-gradient(140deg, rgba(43,140,255,.16), transparent 55%, rgba(255,122,26,.14));
  pointer-events: none;
}

/* Product renders that ship with their own light plate: present them as a
   deliberate chrome plaque instead of fighting the background. */
.split__media--plate {
  background: linear-gradient(150deg, #dfe6ef 0%, #aab6c6 48%, #cfd8e4 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.7), 0 30px 70px -40px #000;
}
/* The render fills the plate corner to corner; `multiply` drops its white field
   so the chrome gradient still reads through it.

   REQUIRES A LIGHT-FIELD SOURCE. Against a dark render `multiply` returns black
   for the whole panel, hiding the plate and leaving the dark corner brackets
   invisible — which is why about.html's sqi_logo_main.png (a black-field mark)
   uses the plain dark panel instead. This variant is currently unused. */
.split__media--plate img { mix-blend-mode: multiply; }
.split__media--plate::after { border-color: rgba(20, 30, 45, 0.16); }
.split__media--plate .media-tag {
  background: rgba(12, 18, 28, 0.82);
  border-color: rgba(255,255,255,.18);
}

/* Panels holding a SCREENSHOT rather than a photograph or artwork. The shared
   rule above sets `object-fit: cover`, which is right for a photo but crops a
   user interface off both edges: this one is `contain` with a little air, so
   every panel in the shot stays readable. The panel's own dark ground shows in
   the letterbox, which is why the padding reads as a frame rather than a gap. */
.split__media--shot {
  background: radial-gradient(ellipse 80% 70% at 50% 42%, rgba(43,140,255,.10), transparent 68%),
              linear-gradient(160deg, #0c1420, #05090f);
}
.split__media--shot img {
  padding: clamp(10px, 2.2%, 22px);
  object-fit: contain;
}

.media-tag {
  position: absolute;
  left: 22px;
  bottom: 22px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(4, 7, 11, 0.72);
  backdrop-filter: blur(8px);
  font-family: var(--font-brand);
  font-size: .58rem;
  letter-spacing: 0.45em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.media-tag::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 10px var(--amber);
  animation: pulseDot 2.2s ease-in-out infinite;
}
@keyframes pulseDot { 0%,100% { opacity: 1; } 50% { opacity: 0.25; } }

/* checklist */
.checks {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 13px;
}
.checks li {
  position: relative;
  padding-left: 32px;
  font-size: 0.96rem;
  color: var(--ink-2);
}
.checks li strong { color: var(--ink); font-weight: 600; }
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(140deg, var(--blue), var(--orange));
  box-shadow: 0 0 12px -2px rgba(255, 122, 26, 0.6);
}

/* ---------- 10b. Team roster ---------------------------------------------
   ADDING A TEAM MEMBER — no CSS changes needed, ever. Copy one whole
   <article class="team-card"> block in about.html and edit four things:
     1. the <img src> (drop a square headshot in assets/team/)
     2. the <img alt>
     3. the .team-card__initials fallback, shown until a photo exists
     4. the name, role, and blurb
   Photos are cropped square and centred, so any square-ish crop works;
   ~600×600 is plenty. If the file is missing the card degrades to the
   initials monogram rather than a broken-image icon.
   ------------------------------------------------------------------------ */
/* Cards are double the old 268px track. The min(100%, …) wrapper is what
   makes them behave on the way down: once the viewport is narrower than a
   single 536px track the column collapses to the full content width rather
   than overflowing, so there is no breakpoint to maintain. */
.team {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 536px), 1fr));
  gap: 22px;
}

.team-card { padding: 22px; }
.team-card__photo {
  position: relative;
  aspect-ratio: 1;
  margin-bottom: 22px;
  border-radius: var(--r);
  border: 1px solid var(--line-strong);
  overflow: hidden;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 32% 28%, rgba(43, 140, 255, 0.30), transparent 62%),
    radial-gradient(circle at 70% 74%, rgba(255, 122, 26, 0.26), transparent 62%),
    var(--bg-3);
}
/* absolute so a missing file leaves the monogram plate perfectly square */
.team-card__photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.team-card:hover .team-card__photo img { transform: scale(1.04); }
.team-card__initials {
  font-family: var(--font-brand);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--ink-3);
}
/* corner brackets, matching .split__media */
.team-card__photo::after {
  content: "";
  position: absolute;
  inset: 10px;
  z-index: 2;
  border: 1px solid rgba(126, 172, 255, 0.18);
  border-radius: var(--r-sm);
  pointer-events: none;
  mask-image: linear-gradient(0deg, #000 0 24%, transparent 24% 76%, #000 76% 100%),
              linear-gradient(90deg, #000 0 24%, transparent 24% 76%, #000 76% 100%);
  -webkit-mask-image: linear-gradient(0deg, #000 0 24%, transparent 24% 76%, #000 76% 100%),
                      linear-gradient(90deg, #000 0 24%, transparent 24% 76%, #000 76% 100%);
  -webkit-mask-composite: source-over;
  mask-composite: add;
}

.team-card h3 { margin-bottom: 6px; }
.team-card__role {
  font-family: var(--font-brand);
  font-size: 0.56rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 14px;
}
.team-card__links {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.team-card__links a {
  font-size: 0.78rem;
  color: var(--ink-3);
  border-bottom: 1px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.team-card__links a:hover { color: var(--cyan); border-bottom-color: rgba(79, 216, 255, 0.5); }

/* An "open role" placeholder — same footprint, deliberately quieter. */
.team-card--open { border-style: dashed; }
.team-card--open .team-card__photo {
  background: var(--bg-2);
  border-style: dashed;
}
.team-card--open .team-card__initials { color: var(--ink-3); opacity: 0.5; }

/* ---------- 11. Environments row ----------------------------------------- */
.envs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  background: var(--bg-2);
}
.env {
  padding: 30px 24px;
  box-shadow: inset -1px -1px 0 var(--line);
  transition: background-color 0.35s var(--ease);
}
.env:hover { background: var(--bg-3); }
.env__k {
  font-family: var(--font-brand);
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  color: var(--amber);
}
.env h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  margin: 12px 0 8px;
}
.env p { font-size: 0.86rem; color: var(--ink-3); line-height: 1.55; }

/* ---------- 12. CTA band -------------------------------------------------- */
.cta-band {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
  padding: clamp(40px, 6vw, 76px) clamp(28px, 5vw, 68px);
  background:
    radial-gradient(900px 400px at 12% 0%,  rgba(43, 140, 255, 0.20), transparent 65%),
    radial-gradient(760px 420px at 92% 100%, rgba(255, 122, 26, 0.20), transparent 65%),
    linear-gradient(160deg, #0a121e, #05090f);
  text-align: center;
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(126,172,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126,172,255,.05) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, #000, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, #000, transparent 75%);
  pointer-events: none;
}
.cta-band > * { position: relative; }
.cta-band .lede { margin-inline: auto; }
.cta-band .btn-row { justify-content: center; }

/* ---------- 13. Footer ----------------------------------------------------
   Column lists are placeholders — drop new <li><a> entries in as pages ship.
   ------------------------------------------------------------------------ */
.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, var(--bg-2), var(--bg));
  padding: clamp(52px, 7vw, 84px) 0 30px;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1fr;           /* phones: one column, no min-width floor */
  gap: clamp(30px, 4vw, 56px);
}
@media (min-width: 640px) {
  .footer__grid { grid-template-columns: repeat(3, 1fr); }
  .footer__about { grid-column: 1 / -1; }
}
@media (min-width: 920px) {
  .footer__grid { grid-template-columns: 1.5fr repeat(3, 1fr); }
  .footer__about { grid-column: auto; }
}
.footer__about { max-width: 42ch; }
.footer__about p {
  margin-top: 18px;
  font-size: 0.9rem;
  color: var(--ink-3);
  line-height: 1.7;
}

.footer__col h5 {
  font-family: var(--font-brand);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 16px;
}
.footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer__col a {
  font-size: 0.89rem;
  color: var(--ink-3);
  transition: color 0.2s var(--ease), padding-left 0.25s var(--ease);
}
.footer__col a:hover { color: var(--amber); padding-left: 5px; }
.footer__col a[data-soon]::after {
  content: "soon";
  margin-left: 8px;
  font-family: var(--font-brand);
  font-size: 0.48rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 176, 46, 0.55);
  vertical-align: middle;
}

.footer__bottom {
  margin-top: clamp(40px, 5vw, 60px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 14px 26px;
  align-items: center;
  justify-content: space-between;
  font-size: 0.79rem;
  color: var(--ink-3);
}
.footer__legal { display: flex; flex-wrap: wrap; gap: 20px; }
.footer__legal a:hover { color: var(--ink-2); }

/* ---------- 14. Scroll reveal -------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.75s var(--ease), transform 0.75s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: 0.09s; }
.reveal[data-delay="2"] { transition-delay: 0.18s; }
.reveal[data-delay="3"] { transition-delay: 0.27s; }
.reveal[data-delay="4"] { transition-delay: 0.36s; }
.reveal[data-delay="5"] { transition-delay: 0.45s; }

/* ---------- 15. Reduced motion / no-JS -----------------------------------
   Motion is gated on <html data-motion>, resolved by the inline script in
   each page's <head> (visitor choice > OS preference). Using the attribute
   instead of the raw media query is what lets the footer toggle bring the
   Vanta background and the ticker back on a machine where Windows has
   animation effects switched off.

   The bare media query below is the no-JS fallback: it only applies while
   the attribute is absent, so it can never fight the resolved value.
   ------------------------------------------------------------------------ */
.no-js .reveal { opacity: 1; transform: none; }

:root[data-motion="reduced"] { scroll-behavior: auto; }
:root[data-motion="reduced"] *,
:root[data-motion="reduced"] *::before,
:root[data-motion="reduced"] *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
}
:root[data-motion="reduced"] .reveal { opacity: 1; transform: none; }

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

/* ---------- 16. Motion toggle -------------------------------------------- */
.motion-toggle {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0;
  font-family: var(--font-brand);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-3);
  transition: color 0.2s var(--ease);
}
.motion-toggle:hover { color: var(--ink-2); }
.motion-toggle__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: transparent;
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.motion-toggle[aria-pressed="true"] .motion-toggle__dot {
  background: var(--amber);
  box-shadow: 0 0 10px var(--amber);
}
