/* ==========================================================================
   Acix. — landing page
   Amber is the single accent and carries meaning: automated / active.
   Teal marks validated output.
   ========================================================================== */

:root {
  --void: #080D18;
  --surface: #0E1526;
  --surface-2: #141D33;
  --line: #232E4B;
  --line-soft: #19223A;
  --ink: #EAEEF7;
  --muted: #8D9AB8;
  --muted-2: #7A87A8;   /* AA (4.5:1) against every surface used on this page */
  --signal: #FFAE3B;
  --clear: #4DD8B0;

  --display: "Bricolage Grotesque", "Instrument Sans", system-ui, sans-serif;
  --body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --gut: clamp(1.25rem, 4.5vw, 4rem);
  --maxw: 1220px;
  --band: clamp(4.5rem, 10vw, 8rem);
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  background: var(--void);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: inherit; }
img, svg { max-width: 100%; }

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

.shell { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut); }

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--signal); color: var(--void);
  padding: .7rem 1.1rem; z-index: 200; font-weight: 600;
}
.skip:focus { left: 1rem; top: 1rem; }

/* --- shared type -------------------------------------------------------- */

.eyebrow {
  font-family: var(--mono);
  font-size: .69rem; font-weight: 500;
  letter-spacing: .19em; text-transform: uppercase;
  color: var(--muted-2);
  margin: 0 0 1.15rem;
  display: flex; align-items: center; gap: .6rem;
}
.eyebrow::before { content: ""; width: 14px; height: 1px; background: var(--signal); flex: none; }

.h2 {
  font-family: var(--display);
  font-size: clamp(1.85rem, 3.6vw, 2.9rem);
  font-weight: 700; letter-spacing: -.032em; line-height: 1.08;
  margin: 0 0 1rem; max-width: 19ch;
}
.sub { color: var(--muted); max-width: 56ch; margin: 0 0 3rem; font-size: 1.02rem; }

/* --- brand lockup ------------------------------------------------------- */

.wordmark {
  font-family: var(--display);
  font-weight: 700; letter-spacing: -.045em;
  line-height: 1; color: var(--ink);
}
.wordmark .dot { color: var(--signal); }

/* --- top bar ------------------------------------------------------------ */

.topbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(8, 13, 24, .82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.topbar.is-stuck { border-bottom-color: var(--line-soft); }

.topbar-in {
  display: flex; align-items: center; gap: 1.5rem;
  height: 68px; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut);
}

.brand { display: inline-flex; align-items: center; text-decoration: none; flex: none; }
.brand .wordmark { font-size: 1.5rem; }

.nav { display: flex; gap: 1.75rem; margin-left: auto; }
.nav a { font-size: .875rem; color: var(--muted); text-decoration: none; transition: color .18s; }
.nav a:hover { color: var(--ink); }

.support-pill {
  display: flex; align-items: center; gap: .45rem;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted-2);
  padding-left: 1.5rem; border-left: 1px solid var(--line-soft);
}
.pulse {
  width: 6px; height: 6px; border-radius: 50%; background: var(--clear); flex: none;
  animation: pulse 2.6s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(77, 216, 176, .45); }
  50% { opacity: .65; box-shadow: 0 0 0 5px rgba(77, 216, 176, 0); }
}

.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--body); font-size: .875rem; font-weight: 600;
  text-decoration: none; white-space: nowrap;
  padding: .68rem 1.15rem; border-radius: 3px;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn-primary { background: var(--signal); color: #16110A; }
.btn-primary:hover { background: #FFC369; transform: translateY(-1px); }
.btn-ghost { border: 1px solid var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--muted-2); background: rgba(255,255,255,.03); }
.btn-arrow { transition: transform .2s; }
.btn:hover .btn-arrow { transform: translateX(3px); }

@media (max-width: 980px) { .nav, .support-pill { display: none; } }
@media (max-width: 560px) { .topbar .btn { display: none; } }

/* --- hero --------------------------------------------------------------- */

.hero { position: relative; padding: clamp(3.5rem, 8vw, 6rem) 0 clamp(3rem, 6vw, 4.5rem); }
.hero-bg {
  position: absolute; inset: 0;
  background-image: url("assets/hero-texture.jpg");
  background-image: image-set(
    url("assets/hero-texture.webp") type("image/webp"),
    url("assets/hero-texture.jpg") type("image/jpeg")
  );
  background-size: cover; background-position: center;
  opacity: .85;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 55%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 55%, transparent 100%);
  pointer-events: none;
}
.hero-in { position: relative; }

.hero h1 {
  font-family: var(--display);
  font-size: clamp(2.7rem, 7.4vw, 5.3rem);
  font-weight: 700; letter-spacing: -.045em; line-height: .97;
  margin: 0 0 1.5rem; max-width: 15ch;
}
.hero h1 .amber { color: var(--signal); }

.lede {
  font-size: clamp(1.04rem, 1.5vw, 1.19rem);
  color: var(--muted); max-width: 54ch; margin: 0 0 2.4rem;
}
.hero-cta { display: flex; gap: .8rem; flex-wrap: wrap; }

/* --- signature: the pipeline diagram ------------------------------------ */

.pipe {
  margin-top: clamp(3rem, 7vw, 4.5rem);
  background: linear-gradient(180deg, var(--surface) 0%, rgba(14,21,38,.55) 100%);
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  padding: clamp(1.1rem, 2.6vw, 1.7rem);
}
/* scroll affordance, only where the diagram actually overflows */
.pipe-hint { display: none; }
@media (max-width: 820px) {
  .pipe-hint {
    display: block; margin: 0 0 .8rem; text-align: right;
    font-family: var(--mono); font-size: .66rem; letter-spacing: .18em;
    text-transform: uppercase; color: var(--signal);
  }
}

.pipe-scroll { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
.pipe-scroll svg { display: block; width: 100%; height: auto; min-width: 660px; }

.src-box { fill: rgba(255,255,255,.03); stroke: var(--line); stroke-width: 1; stroke-dasharray: 3 3; }
.src-txt { font-family: var(--mono); font-size: 10.5px; fill: var(--muted-2); letter-spacing: .08em; }
.core-box { fill: rgba(255,174,59,.04); stroke: var(--signal); stroke-width: 1.4; }
.core-name { font-family: var(--mono); font-size: 12px; font-weight: 500; fill: var(--signal); letter-spacing: .16em; }
.core-sub { font-family: var(--mono); font-size: 9px; fill: var(--muted-2); letter-spacing: .12em; }
.out-box { fill: rgba(77,216,176,.09); stroke: var(--clear); stroke-width: 1; }
.out-txt { font-family: var(--mono); font-size: 10.5px; fill: #B6E9D8; letter-spacing: .06em; }
.zone-lbl { font-family: var(--mono); font-size: 9.5px; fill: var(--muted-2); letter-spacing: .18em; }

.wire { fill: none; stroke: var(--line); stroke-width: 1; }
.wire-flow {
  fill: none; stroke: var(--signal); stroke-width: 1.4;
  stroke-dasharray: 5 170; stroke-linecap: round;
  animation: flow 3.4s linear infinite;
}
@keyframes flow { from { stroke-dashoffset: 175; } to { stroke-dashoffset: 0; } }

.core-pulse { animation: corePulse 3.4s ease-in-out infinite; transform-origin: center; }
@keyframes corePulse {
  0%, 100% { opacity: .03; }
  50% { opacity: .10; }
}

.pipe-foot {
  display: flex; gap: 1.6rem; flex-wrap: wrap;
  margin-top: 1.3rem; padding-top: 1.1rem; border-top: 1px solid var(--line-soft);
  font-family: var(--mono); font-size: .68rem; color: var(--muted-2); letter-spacing: .04em;
}
.pipe-foot b { color: var(--ink); font-weight: 500; }

/* --- proof strip -------------------------------------------------------- */

.proof {
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  background: var(--surface);
}
.proof-grid { display: grid; grid-template-columns: repeat(4, 1fr); max-width: var(--maxw); margin: 0 auto; }
.stat { padding: clamp(1.6rem, 3.4vw, 2.4rem) var(--gut); border-left: 1px solid var(--line-soft); }
.stat:first-child { border-left: 0; }
.stat-n {
  font-family: var(--display);
  font-size: clamp(1.7rem, 3.1vw, 2.4rem);
  font-weight: 700; letter-spacing: -.03em; line-height: 1;
  margin-bottom: .5rem; color: var(--signal);
}
.stat-l { font-size: .82rem; color: var(--muted); line-height: 1.45; }
@media (max-width: 860px) {
  .proof-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line-soft); }
}
@media (max-width: 460px) {
  .proof-grid { grid-template-columns: 1fr; }
  .stat { border-left: 0; }
  .stat + .stat { border-top: 1px solid var(--line-soft); }
}

/* --- generic band ------------------------------------------------------- */

.band { padding: var(--band) 0; }
.band-line { border-top: 1px solid var(--line-soft); }

/* --- client logo wall --------------------------------------------------- */

.wall {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 1px; background: var(--line-soft);
  border: 1px solid var(--line-soft); border-radius: 6px; overflow: hidden;
}
.cell {
  background: var(--surface);
  padding: clamp(1.3rem, 2.6vw, 1.9rem);
  display: flex; flex-direction: column; gap: 1.1rem;
  text-decoration: none; transition: background .25s;
  min-height: 172px;
}
.cell:hover { background: var(--surface-2); }

.cell-logo {
  height: 46px; display: flex; align-items: center; justify-content: flex-start;
}
.cell-logo img {
  max-height: 40px; max-width: 100%; object-fit: contain; object-position: left center;
  filter: brightness(0) invert(1);
  opacity: .82; transition: opacity .25s;
}
.cell:hover .cell-logo img { opacity: 1; }
/* square marks need more height to hold their own beside wordmarks */
.cell-logo.is-square img { max-height: 46px; }
.cell-logo.is-wide img { max-height: 34px; }

/* top-aligned so names line up across the row regardless of description length */
.cell-meta { margin-top: 0; }
.cell-name {
  font-family: var(--display); font-size: 1rem; font-weight: 600;
  letter-spacing: -.018em; margin: 0 0 .45rem;
  display: flex; align-items: center; gap: .45rem;
}
.cell-name .ext { width: 11px; height: 11px; color: var(--muted-2); transition: color .2s, transform .2s; }
.cell:hover .ext { color: var(--signal); transform: translate(2px, -2px); }
.cell-role { font-size: .82rem; color: var(--muted); margin: 0; line-height: 1.45; }

.cell-more {
  background: var(--surface);
  padding: clamp(1.3rem, 2.6vw, 1.9rem);
  display: flex; flex-direction: column; justify-content: center;
  min-height: 172px;
}
.cell-more .big {
  font-family: var(--display); font-size: 2rem; font-weight: 700;
  letter-spacing: -.03em; color: var(--signal); line-height: 1; margin-bottom: .5rem;
}
.cell-more p { margin: 0; font-size: .82rem; color: var(--muted); }

@media (max-width: 900px) { .wall { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) {
  .wall { grid-template-columns: 1fr; }
  .cell, .cell-more { min-height: 0; }
}

/* --- sector split ------------------------------------------------------- */

.sectors { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px;
  background: var(--line-soft); border: 1px solid var(--line-soft);
  border-radius: 6px; overflow: hidden; margin-top: 2.5rem; }
.sector { background: var(--surface); padding: clamp(1.5rem, 3vw, 2.2rem); }
.sector h3 {
  font-family: var(--display); font-size: 1.1rem; font-weight: 600;
  letter-spacing: -.018em; margin: 0 0 .5rem;
}
.sector p { margin: 0; color: var(--muted); font-size: .92rem; }
.sector-tag {
  display: inline-block; font-family: var(--mono); font-size: .6rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--signal);
  border: 1px solid rgba(255,174,59,.3); border-radius: 2px;
  padding: .2rem .5rem; margin-bottom: .9rem;
}
@media (max-width: 720px) { .sectors { grid-template-columns: 1fr; } }

/* --- services ----------------------------------------------------------- */

.svc-grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 1px; background: var(--line-soft);
  border: 1px solid var(--line-soft); border-radius: 5px; overflow: hidden;
}
.svc { background: var(--surface); padding: clamp(1.5rem, 3vw, 2.2rem); transition: background .25s; }
.svc:hover { background: var(--surface-2); }
.svc-ico { color: var(--signal); margin-bottom: 1.1rem; display: block; }
.svc h3 {
  font-family: var(--display); font-size: 1.14rem; font-weight: 600;
  letter-spacing: -.018em; margin: 0 0 .5rem;
}
.svc p { margin: 0; color: var(--muted); font-size: .93rem; }
@media (max-width: 720px) { .svc-grid { grid-template-columns: 1fr; } }

/* --- automation --------------------------------------------------------- */

.auto-wrap {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
}
@media (max-width: 900px) { .auto-wrap { grid-template-columns: 1fr; } }

.flowbox { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 6px; padding: clamp(1.2rem, 2.6vw, 1.8rem); }
.flow-head { font-family: var(--mono); font-size: .64rem; letter-spacing: .17em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 1.2rem; }
.step { display: flex; align-items: center; gap: .8rem; padding: .62rem 0; border-bottom: 1px dashed var(--line-soft); font-size: .87rem; }
.step:last-of-type { border-bottom: 0; }
.step-tag {
  font-family: var(--mono); font-size: .58rem; letter-spacing: .08em;
  text-transform: uppercase; padding: .18rem .42rem; border-radius: 2px;
  flex: none; width: 74px; text-align: center;
}
.step-manual { background: rgba(141,154,184,.13); color: var(--muted); }
.step-auto { background: rgba(255,174,59,.14); color: var(--signal); }
.step-name { color: var(--ink); }
.auto-note { margin-top: 1.2rem; padding-top: 1.1rem; border-top: 1px solid var(--line-soft); font-family: var(--mono); font-size: .7rem; color: var(--muted-2); letter-spacing: .03em; }

.bullets { list-style: none; padding: 0; margin: 2rem 0 0; }
.bullets li { position: relative; padding-left: 1.6rem; margin-bottom: 1rem; color: var(--muted); font-size: .96rem; }
.bullets li::before { content: ""; position: absolute; left: 0; top: .58em; width: 7px; height: 7px; border-radius: 50%; background: var(--signal); }
.bullets b { color: var(--ink); font-weight: 600; }

/* --- approach ----------------------------------------------------------- */

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.6rem, 3.5vw, 3rem); }
.pillar h3 {
  font-family: var(--display); font-size: 1.1rem; font-weight: 600;
  letter-spacing: -.018em; margin: 0 0 .6rem;
  padding-top: 1.1rem; border-top: 2px solid var(--signal);
}
.pillar p { margin: 0; color: var(--muted); font-size: .93rem; }
@media (max-width: 820px) { .pillars { grid-template-columns: 1fr; } }

/* --- contact ------------------------------------------------------------ */

.contact-card {
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: 6px;
  padding: clamp(2rem, 5vw, 3.6rem);
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(1.8rem, 4vw, 3.5rem); align-items: center;
}
@media (max-width: 820px) { .contact-card { grid-template-columns: 1fr; } }

.contact-h { font-family: var(--display); font-size: clamp(1.6rem, 3.3vw, 2.5rem); font-weight: 700; letter-spacing: -.032em; line-height: 1.1; margin: 0 0 .9rem; }
.contact-p { color: var(--muted); margin: 0; max-width: 42ch; }
.contact-actions { display: flex; flex-direction: column; align-items: flex-start; gap: .9rem; }
.mail { font-family: var(--mono); font-size: .95rem; color: var(--signal); text-decoration: none; word-break: break-all; }
.mail:hover { text-decoration: underline; }

/* --- footer ------------------------------------------------------------- */

.footer { border-top: 1px solid var(--line-soft); padding: 2.4rem 0 3rem; }
.footer-in {
  display: flex; justify-content: space-between; gap: 1.2rem; flex-wrap: wrap; align-items: center;
  font-family: var(--mono); font-size: .67rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted-2);
}
.footer-in a { text-decoration: none; }
.footer-in a:hover { color: var(--ink); }
.footer-in .wordmark { font-size: 1.1rem; letter-spacing: -.04em; text-transform: none; }

/* --- reveal on scroll ----------------------------------------------------
   Gated on .js so the page is fully readable if JavaScript never runs. */

.js .rv { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.22,1,.36,1); }
.js .rv.in { opacity: 1; transform: none; }

.up { opacity: 0; transform: translateY(16px); animation: up .8s cubic-bezier(.22,1,.36,1) forwards; }
@keyframes up { to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .js .rv, .js .rv.in { opacity: 1; transform: none; }
  .up { opacity: 1; transform: none; }
  .wire-flow { display: none; }
  .core-pulse { opacity: .12; }
}
