/* =========================================================================
   TRIPLETS by EnigmaVault — shared design system
   Dark, premium, engineered. Brand blue + verified-green + refusal-amber.
   Type: Space Grotesk (display) · IBM Plex Sans (body) · IBM Plex Mono (data)
   ========================================================================= */

:root {
  /* surfaces */
  --bg:        #06080f;
  --bg-1:      #080b15;
  --panel:     #0b101e;
  --panel-2:   #0f1626;
  --raised:    #131c30;
  --line:      rgba(150,170,210,.12);
  --line-2:    rgba(150,170,210,.22);

  /* ink */
  --ink:       #eef2fb;
  --ink-2:     #b3bfd6;
  --muted:     #7c89a4;
  --faint:     #586481;

  /* brand + semantics */
  --blue:      #0078e7;
  --blue-ink:  #56a9ff;
  --blue-soft: rgba(0,120,231,.14);
  --green:     #1fc98a;
  --green-ink: #4fe3a8;
  --green-soft:rgba(31,201,138,.14);
  --amber:     #f4a73a;
  --amber-ink: #ffc068;
  --amber-soft:rgba(244,167,58,.14);

  /* type */
  --display: "Space Grotesk", system-ui, sans-serif;
  --body:    "IBM Plex Sans", system-ui, sans-serif;
  --mono:    "IBM Plex Mono", ui-monospace, monospace;

  --maxw: 1200px;
  --gut: 28px;
  --radius: 16px;
  --radius-sm: 11px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--body);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ambient glow field for the whole page */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(680px 520px at 50% -8%, rgba(0,120,231,.20), transparent 60%),
    radial-gradient(900px 700px at 88% 4%, rgba(31,201,138,.06), transparent 55%),
    radial-gradient(800px 600px at 6% 18%, rgba(0,120,231,.07), transparent 60%);
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---- layout ---- */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut); }
.section { position: relative; z-index: 1; padding: clamp(72px, 9vw, 132px) 0; }
.section.tight { padding: clamp(48px, 6vw, 84px) 0; }
.relz { position: relative; z-index: 1; }

/* ---- type ---- */
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; letter-spacing: -.02em; line-height: 1.04; margin: 0; }
h1 { font-size: clamp(2.6rem, 5.6vw, 4.7rem); }
h2 { font-size: clamp(2rem, 3.8vw, 3.25rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); letter-spacing: -.015em; }
p  { margin: 0; color: var(--ink-2); }
.lead { font-size: clamp(1.06rem, 1.45vw, 1.28rem); color: var(--ink-2); max-width: 60ch; }

.eyebrow {
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--blue-ink);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
}
.eyebrow::before {
  content: "";
  width: 24px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--blue-ink));
}
.eyebrow.center { justify-content: center; }
.eyebrow.center::after {
  content: "";
  width: 24px; height: 1px;
  background: linear-gradient(90deg, var(--blue-ink), transparent);
}
.eyebrow.green { color: var(--green-ink); }
.eyebrow.green::before, .eyebrow.green.center::after { background-image: linear-gradient(90deg, transparent, var(--green-ink)); }
.eyebrow.amber { color: var(--amber-ink); }

.grad-blue { color: var(--blue-ink); }
.grad-green { color: var(--green-ink); }
.grad-amber { color: var(--amber-ink); }

.center-head { text-align: center; max-width: 780px; margin: 0 auto; }
.center-head .lead { margin: 22px auto 0; }

/* ---- buttons ---- */
.btn {
  font-family: var(--body);
  font-weight: 600;
  font-size: .98rem;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 22px;
  border-radius: 100px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .25s ease, background .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 10px 30px -10px rgba(0,120,231,.7);
}
.btn-primary:hover { box-shadow: 0 16px 40px -10px rgba(0,120,231,.85); }
.btn-ghost {
  background: rgba(255,255,255,.03);
  border-color: var(--line-2);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--blue-ink); background: rgba(0,120,231,.08); }
.btn-green { background: var(--green); color: #042417; box-shadow: 0 10px 30px -10px rgba(31,201,138,.6); }
.btn .arr { transition: transform .2s ease; }
.btn:hover .arr { transform: translateX(3px); }

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }
.btn-row.center { justify-content: center; }

/* ---- nav ---- */
.utility {
  position: relative;
  z-index: 30;
  border-bottom: 1px solid var(--line);
  background: rgba(6,8,15,.6);
  backdrop-filter: blur(8px);
}
.utility .wrap { display: flex; align-items: center; justify-content: space-between; height: 38px; }
.utility a, .utility span { font-family: var(--mono); font-size: .72rem; letter-spacing: .04em; color: var(--muted); white-space: nowrap; }
.utility .u-links { display: flex; gap: 22px; min-width: 0; }
.utility .u-links a:hover { color: var(--ink); }
.utility .u-tag { display: flex; align-items: center; gap: 8px; color: var(--faint); }
.utility .u-tag b { color: var(--blue-ink); font-weight: 500; }

.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid transparent;
  transition: background .3s ease, border-color .3s ease, backdrop-filter .3s ease;
}
.nav.scrolled {
  background: rgba(7,10,18,.82);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand .mark { width: 30px; height: 30px; flex: none; }
.brand .word { font-family: var(--display); font-weight: 700; font-size: 1.18rem; letter-spacing: -.02em; }
.brand .word small { display: block; font-family: var(--mono); font-weight: 400; font-size: .56rem; letter-spacing: .22em; color: var(--muted); text-transform: uppercase; margin-top: -2px; }

.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links a {
  font-size: .94rem;
  color: var(--ink-2);
  padding: 8px 15px;
  border-radius: 9px;
  transition: color .18s ease, background .18s ease;
}
.nav-links a:hover { color: var(--ink); background: rgba(255,255,255,.04); }
.nav-links a.active { color: var(--ink); }
.nav-links a.active::after {
  content: ""; display: block; height: 2px; margin: 5px 12px 0;
  border-radius: 2px; background: var(--blue);
}
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; }

/* ---- generic card ---- */
.card {
  position: relative;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.card:hover { border-color: var(--line-2); transform: translateY(-3px); box-shadow: 0 24px 50px -28px rgba(0,0,0,.8); }

.chip {
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  font-family: var(--mono); font-size: .72rem; letter-spacing: .04em;
  padding: 6px 12px; border-radius: 100px;
  border: 1px solid var(--line-2); color: var(--ink-2);
  background: rgba(255,255,255,.02);
}
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot.blue { background: var(--blue-ink); box-shadow: 0 0 12px var(--blue-ink); }
.dot.green { background: var(--green-ink); box-shadow: 0 0 12px var(--green-ink); }
.dot.amber { background: var(--amber-ink); box-shadow: 0 0 12px var(--amber-ink); }

.icon-badge {
  width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center; flex: none;
  border: 1px solid var(--line-2);
}
.icon-badge.blue { background: var(--blue-soft); color: var(--blue-ink); }
.icon-badge.green { background: var(--green-soft); color: var(--green-ink); }
.icon-badge.amber { background: var(--amber-soft); color: var(--amber-ink); }
.icon-badge svg { width: 22px; height: 22px; }

/* ---- footer ---- */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--line); background: var(--bg-1); padding: 64px 0 30px; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr; gap: 32px; }
.footer .f-brand { max-width: 280px; }
.footer .f-brand p { color: var(--muted); font-size: .9rem; margin-top: 16px; }
.footer h5 { font-family: var(--mono); font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: var(--faint); margin: 0 0 16px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.footer ul a { color: var(--ink-2); font-size: .92rem; }
.footer ul a:hover { color: var(--blue-ink); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; margin-top: 52px; padding-top: 24px; border-top: 1px solid var(--line); }
.footer-bottom span, .footer-bottom a { font-family: var(--mono); font-size: .74rem; color: var(--faint); letter-spacing: .03em; }

/* ---- scroll reveal ----
   NOTE: base state is fully visible. The preview compositor can freeze CSS
   transitions (an opacity 0->1 transition stays stuck at 0), which would
   blank content. So content is never hidden by default; the .in class only
   adds a gentle, frozen-safe transform settle that can never hide anything. */
.reveal { opacity: 1; transform: translateY(10px); transition: transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { transform: none; }
.reveal.d1 { transition-delay: .05s; }
.reveal.d2 { transition-delay: .1s; }
.reveal.d3 { transition-delay: .15s; }
.reveal.d4 { transition-delay: .2s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---- divider with triad ---- */
.triad-rule { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 auto; }
.triad-rule .ln { height: 1px; width: min(120px, 18vw); background: linear-gradient(90deg, transparent, var(--line-2)); }
.triad-rule .ln.r { background: linear-gradient(90deg, var(--line-2), transparent); }
.triad-rule i { width: 7px; height: 7px; border-radius: 50%; display: block; }

/* ---- responsive ---- */
@media (max-width: 920px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
  .footer .f-brand { grid-column: 1 / -1; max-width: none; }
}
@media (max-width: 760px) {
  .utility .u-tag { display: none; }
  .nav-links {
    position: fixed; inset: 0 0 auto 0; top: 108px;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: rgba(8,11,20,.97); backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line);
    padding: 14px var(--gut); transform: translateY(-130%);
    transition: transform .32s cubic-bezier(.3,.8,.3,1);
  }
  .nav-links.open { transform: none; }
  .nav-links a { padding: 14px 12px; font-size: 1.05rem; }
  .nav-links a.active::after { display: none; }
  .nav-toggle {
    display: inline-grid; place-items: center; width: 42px; height: 42px;
    border-radius: 10px; border: 1px solid var(--line-2);
    background: rgba(255,255,255,.03); cursor: pointer;
  }
  .nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
    content: ""; display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px; position: relative;
  }
  .nav-toggle span::before { position: absolute; top: -6px; }
  .nav-toggle span::after { position: absolute; top: 6px; }
  .nav-cta .btn.desktop-cta { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}
@media (max-width: 480px) {
  .footer-top { grid-template-columns: 1fr; }
}
