:root {
  /* Ground + text */
  --color-bg: #201e1d;                        /* ink ground */
  --color-text: #f3f2f2;                      /* off-white primary */
  --color-text-body: rgba(243, 242, 242, 0.88);
  --color-text-muted: rgba(243, 242, 242, 0.65);

  /* Surfaces */
  --color-surface: #2a2827;                   /* ticker, cards, testimonial band */
  --color-surface-hover: #33302f;             /* card hover, contact-btn hover */

  /* Accent */
  --color-accent: #7C4DFF;                    /* violet, all fills + large accent numbers */
  --color-accent-tint: #b394ff;               /* accent-400 for accent-toned text on dark */
  --color-accent-hover: #6f3fe8;              /* accent-600 for hover on violet buttons */

  /* Rules */
  --rule-soft: rgba(243, 242, 242, 0.14);
  --rule-med: rgba(243, 242, 242, 0.15);
  --rule-strong: rgba(243, 242, 242, 0.28);
  --rule-outline: rgba(243, 242, 242, 0.35);

  /* Layout */
  --max-width: 1240px;
  --pad-x: 48px;
  --section-y: 96px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: 'Space Grotesk', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--color-text); text-decoration: none; transition: color 120ms ease, background 120ms ease, border-color 120ms ease; }
a:hover { color: var(--color-accent); }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }

::selection { background: color-mix(in srgb, var(--color-accent) 40%, transparent); }

h1, h2, h3, h4 { font-family: 'Space Grotesk', system-ui, sans-serif; margin: 0; }

/* ── Nav ─────────────────────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--pad-x);
  background: rgba(32, 30, 29, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--rule-soft);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: var(--color-accent);
  color: var(--color-text);
  font-weight: 700;
  font-size: 17px;
}
.brand-word {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.06em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 14px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
}
.nav-link {
  color: var(--color-text-muted);
}
.nav-link:hover {
  color: var(--color-accent);
}

.btn-cta-nav {
  padding: 10px 20px;
  background: var(--color-accent);
  color: var(--color-text);
  font-weight: 500;
}
.btn-cta-nav:hover {
  background: var(--color-accent-hover);
  color: var(--color-text);
}

/* ── Hero ────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  padding: 96px var(--pad-x) 64px;
  background-image:
    linear-gradient(rgba(243, 242, 242, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 242, 242, 0.04) 1px, transparent 1px);
  background-size: 56px 56px;
}

.hero-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: center;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 28px;
  align-items: flex-start;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--color-accent-tint);
}
.eyebrow-hero { display: flex; }
.eyebrow-square {
  width: 10px;
  height: 10px;
  background: var(--color-accent);
  transform: rotate(45deg);
  flex: none;
}

.hero-title {
  font-size: 72px;
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.accent-text { color: var(--color-accent); }

.hero-sub {
  margin: 0;
  max-width: 560px;
  font-size: 19px;
  line-height: 1.55;
  color: var(--color-text-muted);
  text-wrap: pretty;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  font-family: inherit;
  font-size: 16px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: color 120ms ease, background 120ms ease, border-color 120ms ease;
}
.btn-primary {
  background: var(--color-accent);
  color: var(--color-text);
  font-weight: 600;
}
.btn-primary:hover {
  background: var(--color-accent-hover);
  color: var(--color-text);
}
.btn-outline {
  border: 1px solid var(--rule-outline);
  color: var(--color-text);
  font-weight: 500;
}
.btn-outline:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.hero-glyph {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 380px;
}
.glyph-outline {
  font-size: 300px;
  font-weight: 700;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 2px var(--color-accent);
  opacity: 0.9;
  user-select: none;
}
.shape { position: absolute; }
.shape-square-a {
  top: 12%;
  right: 8%;
  width: 22px;
  height: 22px;
  background: var(--color-accent);
}
.shape-square-b {
  bottom: 10%;
  left: 4%;
  width: 16px;
  height: 16px;
  background: var(--color-accent);
  transform: rotate(45deg);
}
.shape-diamond {
  bottom: 22%;
  right: 2%;
  width: 44px;
  height: 44px;
  border: 2px solid var(--rule-outline);
  transform: rotate(45deg);
}

/* ── Stats strip ─────────────────────────────────────────────────────── */
.stats {
  max-width: var(--max-width);
  margin: 72px auto 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--rule-med);
  background: rgba(32, 30, 29, 0.6);
}
.stat {
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-right: 1px solid var(--rule-med);
}
.stat:last-child { border-right: 0; }
.stat-num {
  font-size: 30px;
  font-weight: 700;
  color: var(--color-accent);
}
.stat-cap {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
}

/* ── Ticker ──────────────────────────────────────────────────────────── */
.ticker {
  overflow: hidden;
  border-top: 1px solid var(--rule-med);
  border-bottom: 1px solid var(--rule-med);
  padding: 14px 0;
  background: var(--color-surface);
}
.ticker-track {
  display: flex;
  width: max-content;
  animation: marquee 36s linear infinite;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 13px;
  letter-spacing: 0.16em;
  color: var(--color-text-muted);
  white-space: nowrap;
}
.ticker-item {
  padding-right: 32px;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
}

/* ── Section shell ───────────────────────────────────────────────────── */
.section {
  padding: var(--section-y) var(--pad-x);
}
.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 48px;
}
.h2 {
  font-size: 44px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* ── Services ────────────────────────────────────────────────────────── */
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}
.section-head-left {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.section-intro {
  margin: 0;
  max-width: 400px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--color-text-muted);
  text-wrap: pretty;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 32px 28px;
  background: var(--color-surface);
  border: 1px solid var(--rule-soft);
  border-top: 3px solid var(--rule-soft);
  transition: border-top-color 160ms ease, background 160ms ease;
}
.card:hover {
  border-top-color: var(--color-accent);
  background: var(--color-surface-hover);
}
.card-num {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 14px;
  color: var(--color-accent-tint);
}
.card-title {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}
.card-desc {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-text-muted);
  text-wrap: pretty;
}
.card-list {
  list-style: none;
  padding: 0;
  margin: auto 0 0;
  padding-top: 12px;
  border-top: 1px solid var(--rule-soft);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.card-list li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 14px;
  color: var(--color-text-body);
}
.bullet {
  width: 7px;
  height: 7px;
  background: var(--color-accent);
  flex: none;
  transform: rotate(45deg) translateY(-1px);
}

/* ── Track record ────────────────────────────────────────────────────── */
.section-work {
  padding-top: 0;
}
.work-head {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.work-sub {
  margin: 0;
  font-size: 14px;
  color: var(--color-text-muted);
}

.table {
  border-top: 1px solid var(--rule-strong);
}
.table-head,
.table-row {
  display: grid;
  grid-template-columns: 340px 1fr 140px;
  gap: 32px;
  border-bottom: 1px solid var(--rule-med);
}
.table-head {
  padding: 12px 0;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--color-text-muted);
}
.table-head .sector-col { justify-self: end; }
.table-row {
  padding: 28px 0;
  align-items: start;
}
.client {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.client-name {
  font-size: 20px;
  font-weight: 700;
}
.client-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--color-text-muted);
  text-wrap: pretty;
}
.scope {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  text-wrap: pretty;
}
.sector-tag {
  justify-self: end;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border: 1px solid var(--color-accent);
  color: var(--color-accent-tint);
  white-space: nowrap;
}

/* ── Testimonial ─────────────────────────────────────────────────────── */
.testimonial {
  background: var(--color-surface);
  border-top: 1px solid var(--rule-med);
  border-bottom: 1px solid var(--rule-med);
}
.testimonial-inner {
  gap: 28px;
  align-items: flex-start;
}
.testimonial-head {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.placeholder-tag {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border: 1px solid var(--rule-outline);
  color: var(--color-text-muted);
}
.quote {
  margin: 0;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
  max-width: 980px;
  text-wrap: balance;
}
.attribution {
  display: flex;
  align-items: center;
  gap: 14px;
}
.attribution-dash {
  width: 32px;
  height: 2px;
  background: var(--color-accent);
  flex: none;
}
.attribution-text {
  display: flex;
  flex-direction: column;
}
.attribution-name {
  font-weight: 700;
  font-size: 15px;
}
.attribution-role {
  font-size: 13px;
  color: var(--color-text-muted);
}

/* ── Contact banner ──────────────────────────────────────────────────── */
.contact {
  padding: 112px var(--pad-x);
  background: var(--color-accent);
  color: var(--color-text);
}
.contact-inner {
  gap: 24px;
  align-items: flex-start;
}
.contact-eyebrow {
  color: var(--color-text);
  opacity: 0.75;
}
.contact-title {
  font-size: 64px;
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.02em;
  max-width: 820px;
  text-wrap: balance;
}
.contact-body {
  margin: 0;
  font-size: 18px;
  line-height: 1.55;
  max-width: 560px;
  opacity: 0.85;
  text-wrap: pretty;
}
.btn-contact {
  margin-top: 8px;
  padding: 16px 32px;
  background: var(--color-bg);
  color: var(--color-text);
  font-weight: 600;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn-contact:hover {
  background: var(--color-surface-hover);
  color: var(--color-text);
}

/* ── Footer ──────────────────────────────────────────────────────────── */
.footer {
  padding: 24px var(--pad-x);
  display: flex;
  align-items: center;
  gap: 24px;
  border-top: 1px solid var(--rule-med);
  flex-wrap: wrap;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.06em;
  margin-right: auto;
}
.footer-mark {
  width: 20px;
  height: 20px;
  background: var(--color-accent);
  color: var(--color-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
}
.footer-copy {
  font-size: 13px;
  color: var(--color-text-muted);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
}
.footer-top {
  font-size: 13px;
  color: var(--color-text-muted);
}
.footer-top:hover { color: var(--color-accent); }

/* ── About modal ─────────────────────────────────────────────────────── */
.about-modal {
  padding: 0;
  border: 1px solid var(--rule-med);
  background: var(--color-surface);
  color: var(--color-text);
  max-width: 640px;
  width: calc(100% - 40px);
  max-height: 85vh;
  overflow: hidden;
  position: fixed;
  inset: 0;
  margin: auto;
}
.about-modal::backdrop {
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.about-modal-inner {
  padding: 40px;
  max-height: 85vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
  align-items: flex-start;
}

.about-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 0;
  color: var(--color-text-muted);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  padding: 0;
  z-index: 1;
  transition: color 120ms ease;
}
.about-close:hover { color: var(--color-accent); }

.about-title {
  margin: 0;
  font-size: 36px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 700;
}

.about-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--rule-soft);
  width: 100%;
}
.about-block:first-of-type { border-top: 0; padding-top: 0; }

.about-h3 {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.25;
}

.about-founder {
  display: flex;
  align-items: center;
  gap: 18px;
  width: 100%;
  margin-bottom: 4px;
}
.about-founder .about-h3 {
  margin: 0;
  line-height: 1.2;
}
.about-photo {
  width: 88px;
  height: 88px;
  object-fit: cover;
  flex: none;
  border: 1px solid var(--rule-soft);
  display: block;
}
.about-block p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-text-body);
  text-wrap: pretty;
}

.about-creds {
  list-style: none;
  padding: 0;
  margin: 4px 0 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.about-creds li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 14px;
  color: var(--color-text-body);
}

.about-external {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--color-accent-tint);
  text-decoration: none;
  align-self: flex-start;
  margin-top: 4px;
}
.about-external:hover { color: var(--color-accent); }

.about-actions {
  padding-top: 8px;
  width: 100%;
}
.about-actions .btn { padding: 14px 28px; font-size: 15px; }

/* ── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 960px) {
  :root { --pad-x: 32px; --section-y: 72px; }

  .hero { padding: 64px var(--pad-x) 48px; }
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .hero-glyph { min-height: 280px; }
  .glyph-outline { font-size: 220px; }
  .hero-title { font-size: 56px; }

  .stats { grid-template-columns: repeat(2, 1fr); margin-top: 56px; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(1), .stat:nth-child(2) { border-bottom: 1px solid var(--rule-med); }

  .section-head { flex-direction: column; align-items: flex-start; }

  .cards { grid-template-columns: 1fr; }

  .table-head { display: none; }
  .table-row {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 24px 0;
  }
  .sector-tag { justify-self: start; }

  .quote { font-size: 28px; }
  .contact { padding: 80px var(--pad-x); }
  .contact-title { font-size: 44px; }
}

@media (max-width: 640px) {
  :root { --pad-x: 20px; }

  .hero-title { font-size: 40px; line-height: 1.05; }
  .hero-sub { font-size: 17px; }
  .glyph-outline { font-size: 160px; }
  .hero-glyph { min-height: 200px; }

  .nav { padding: 14px var(--pad-x); }
  .nav-links { gap: 16px; font-size: 12px; }
  .nav-link { display: none; }
  .nav-link[data-open-about] { display: inline; } /* keep ABOUT reachable on mobile */
  .btn-cta-nav { padding: 8px 14px; font-size: 12px; }

  .stats { grid-template-columns: 1fr; }
  .stat { border-right: 0 !important; border-bottom: 1px solid var(--rule-med); }
  .stat:last-child { border-bottom: 0; }

  .h2 { font-size: 32px; }
  .card-title { font-size: 20px; }

  .quote { font-size: 22px; }
  .contact-title { font-size: 32px; }
  .contact-body { font-size: 16px; }

  .btn { padding: 14px 24px; font-size: 15px; width: 100%; }
  .hero-actions { width: 100%; flex-direction: column; }
  .btn-contact { width: auto; }

  .footer { padding: 20px var(--pad-x); gap: 12px; }
  .footer-copy, .footer-top { font-size: 12px; }

  .about-modal { width: calc(100% - 24px); max-height: 90vh; }
  .about-modal-inner { padding: 32px 24px; max-height: 90vh; gap: 20px; }
  .about-title { font-size: 26px; }
  .about-h3 { font-size: 16px; }
  .about-founder { gap: 14px; }
  .about-photo { width: 68px; height: 68px; }
  .about-actions .btn { width: 100%; }
}
