/* Nex Gen Inc. — editorial industrial style
   Palette: ink #0d0e13 · cream #f3ede3 / #e5e2dd / #dcd8d3 · paper #fbf8f3 · accent #c8603d */

:root {
  --ink: #0d0e13;
  --ink-soft: #191b21;
  --cream: #f3ede3;
  --cream-bg: #e5e2dd;
  --cream-tile: #dcd8d3;
  --paper: #fbf8f3;
  --accent: #c8603d;
  --muted: #6f6c66;
  --muted-dark: #8b8d94;
  --pad: clamp(1.25rem, 4vw, 4rem);
  --radius: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent); color: var(--paper); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .8rem 1.5rem;
  font: 600 .82rem/1 "Inter", sans-serif;
  letter-spacing: -.01em;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color .25s, color .25s, border-color .25s;
}
.btn--accent { background: var(--accent); color: var(--paper); }
.btn--accent:hover { background: #a94e30; }
.btn--outline-light { border-color: rgba(243, 237, 227, .35); color: var(--cream); background: transparent; }
.btn--outline-light:hover { border-color: var(--cream); }
.btn--outline-dark { border-color: rgba(13, 14, 19, .35); color: var(--ink); background: transparent; }
.btn--outline-dark:hover { border-color: var(--ink); }
.btn--wide { width: 100%; padding: 1rem; }

/* ---------- topbar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem var(--pad);
  background: rgba(13, 14, 19, .85);
  backdrop-filter: blur(12px);
  color: var(--cream);
}
.topbar__brand {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -.03em;
  color: var(--cream);
  text-decoration: none;
}
.topbar__brand sup { font-size: .5em; font-weight: 500; }
.topbar__mark { width: 2.1rem; height: auto; }
.topbar__nav { display: flex; gap: 1.75rem; }
.topbar__nav a {
  color: var(--cream);
  text-decoration: none;
  font-size: .82rem;
  font-weight: 500;
  opacity: .75;
  transition: opacity .2s;
}
.topbar__nav a:hover { opacity: 1; }
.topbar__actions { display: flex; gap: .6rem; }
.topbar__actions .btn { padding: .6rem 1.1rem; font-size: .76rem; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: min(92vh, 820px);
  background: radial-gradient(120% 90% at 50% 8%, #1a1c24 0%, var(--ink) 58%);
  color: var(--cream);
  text-align: center;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  isolation: isolate;
}

/* ---- scene ---- */
.hero__scene { position: absolute; inset: 0; z-index: 0; pointer-events: none; }

.hero__glow {
  position: absolute;
  left: 50%;
  bottom: 20%;
  width: 90vw;
  max-width: 1100px;
  aspect-ratio: 2 / 1;
  transform: translate(-50%, 0);
  background: radial-gradient(60% 60% at 50% 50%, rgba(200, 96, 61, .28), transparent 70%);
  filter: blur(20px);
  will-change: transform;
}

/* motion streaks */
.hero__streaks { position: absolute; inset: 0; overflow: hidden; }
.hero__streaks span {
  position: absolute;
  right: -30%;
  height: var(--h, 2px);
  width: 45%;
  background: linear-gradient(90deg, transparent, rgba(255, 207, 148, var(--o, .3)));
  border-radius: 2px;
  animation: streak var(--d, 6s) linear infinite;
}
@keyframes streak {
  0%   { transform: translateX(0); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateX(-170vw); opacity: 0; }
}

/* truck */
.hero__drive {
  position: absolute;
  left: 50%;
  bottom: 9%;
  width: min(72vw, 700px);
  transform: translateX(-50%);
  will-change: transform;
}
.hero__truck {
  display: block;
  width: 100%;
  height: auto;
  animation: bob 3.2s ease-in-out infinite;
}
@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-6px) rotate(-.25deg); }
}
.hero__beam { animation: flicker 4.5s ease-in-out infinite; transform-origin: 656px 192px; }
@keyframes flicker { 0%, 100% { opacity: .9; } 45% { opacity: .68; } 70% { opacity: 1; } }
.hero__lamp { animation: flicker 4.5s ease-in-out infinite; }
.hero__hubs g { animation: roll 1.1s linear infinite; }
@keyframes roll { to { transform: rotate(360deg); } }

/* ground line + light pool under the truck */
.hero__ground {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 9%;
  height: 40%;
  background:
    radial-gradient(60% 80% at 50% 100%, rgba(200, 96, 61, .16), transparent 70%),
    linear-gradient(to top, rgba(13, 14, 19, .9), transparent 60%);
}
.hero__ground::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(82vw, 900px);
  height: 2px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(255, 207, 148, .5) 30%, rgba(255, 207, 148, .5) 70%, transparent);
}

/* ---- copy ---- */
.hero__content {
  position: relative;
  z-index: 2;
  padding: clamp(2.5rem, 9vh, 6rem) var(--pad) 0;
}
.hero__badge {
  display: inline-block;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(200, 96, 61, .4);
  border-radius: 999px;
  padding: .4rem .9rem;
  margin-bottom: 1.5rem;
  background: rgba(200, 96, 61, .08);
}
.hero__title {
  font-size: clamp(2.8rem, 9.5vw, 7rem);
  font-weight: 500;
  line-height: .95;
  letter-spacing: -.05em;
  text-shadow: 0 8px 40px rgba(13, 14, 19, .55);
}
.hero__title span { display: block; }
.hero__sub {
  max-width: 30em;
  margin: 1.5rem auto 0;
  font-size: clamp(.95rem, 1.5vw, 1.15rem);
  color: var(--muted-dark);
}
.hero__cta { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; margin-top: 2rem; }

/* ---------- shared section chrome ---------- */
.section--cream { background: var(--cream-bg); color: var(--ink); }

.micro-label {
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .04em;
  color: var(--muted);
  padding: 0 var(--pad);
  margin-bottom: 2.5rem;
}

.link-arrow {
  display: inline-block;
  color: var(--ink);
  font-weight: 500;
  font-size: .9rem;
  text-decoration: none;
  border-bottom: 1px solid var(--ink);
  padding-bottom: .2rem;
  transition: color .2s, border-color .2s;
}
.link-arrow:hover { color: var(--accent); border-color: var(--accent); }
.link-arrow--big { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 600; letter-spacing: -.03em; }
.link-arrow--light { color: var(--cream); border-color: rgba(243, 237, 227, .5); }
.link-arrow--light:hover { color: var(--accent); border-color: var(--accent); }

/* ---------- about (full-width dark block) ---------- */
.about {
  position: relative;
  background: var(--ink);
  color: var(--cream);
  padding: clamp(4rem, 11vh, 8rem) var(--pad);
  overflow: hidden;
}
.about__triangle {
  position: absolute;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 clamp(180px, 26vw, 420px) clamp(180px, 26vw, 420px) 0;
  border-color: transparent rgba(200, 96, 61, .14) transparent transparent;
  pointer-events: none;
}
.about__box { position: relative; z-index: 1; max-width: 900px; margin: 0 auto; }
.micro-label--light { color: var(--muted-dark); padding: 0; }
.about__headline {
  font-size: clamp(2rem, 5.2vw, 3.6rem);
  font-weight: 600;
  letter-spacing: -.04em;
  line-height: 1.05;
  margin: .5rem 0 1.5rem;
}
.about__text {
  font-size: clamp(1rem, 1.6vw, 1.25rem);
  line-height: 1.65;
  letter-spacing: -.01em;
  max-width: 40em;
  margin-bottom: 1.75rem;
  color: var(--cream);
}

/* ---------- services ---------- */
.services { padding: clamp(4rem, 10vh, 7rem) 0; }
.services__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: .85rem;
  padding: 0 var(--pad);
  max-width: 1200px;
  margin: 0 auto 2.5rem;
}
.product {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  background: var(--cream-tile);
  color: var(--ink);
}
.product__tile {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 9px;
  background: var(--paper);
}
.product__tile svg {
  width: 62%;
  fill: none;
  stroke: var(--ink);
  stroke-width: 2.4;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.product__tile .flake { stroke: var(--accent); stroke-width: 1.6; }
.product__body { display: flex; flex-direction: column; gap: .15rem; }
.product__name { font-weight: 600; font-size: 1rem; letter-spacing: -.02em; }
.product__desc { font-size: .82rem; color: var(--muted); }
.services__cta { margin-left: var(--pad); }

/* ---------- specialty ---------- */
.specialty { padding: clamp(4rem, 10vh, 7rem) 0; }
.specialty__grid {
  display: flex;
  flex-wrap: wrap;
  gap: .85rem;
  padding: 0 var(--pad);
  max-width: 1200px;
  margin: 0 auto;
}
.area {
  display: flex;
  align-items: center;
  gap: .85rem;
  padding: 1.1rem 1.35rem;
  border-radius: var(--radius);
  background: var(--cream-tile);
  color: var(--ink);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -.02em;
}
.area__icon {
  flex: none;
  width: 1.5rem;
  height: 1.5rem;
  color: var(--accent);
}
.specialty__note {
  padding: 2.5rem var(--pad) 0;
  max-width: 1200px;
  margin: 0 auto;
  font-size: .78rem;
  letter-spacing: .03em;
  color: var(--muted);
}

/* ---------- approach (full-width dark block) ---------- */
.approach {
  position: relative;
  background: var(--ink);
  color: var(--cream);
  padding: clamp(4rem, 11vh, 8rem) var(--pad);
  overflow: hidden;
}
.approach .micro-label--light { position: relative; z-index: 1; max-width: 900px; margin: 0 auto 2.5rem; }
.approach__stats {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
}
.stat { border-top: 1px solid rgba(243, 237, 227, .18); padding-top: 1.25rem; }
.stat strong {
  display: block;
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  font-weight: 500;
  letter-spacing: -.04em;
  line-height: 1;
  color: var(--cream);
  margin-bottom: .6rem;
}
.stat span:last-child { font-size: .82rem; color: var(--muted-dark); }

/* ---------- CTA ---------- */
.cta { padding: clamp(4rem, 12vh, 8rem) var(--pad); text-align: center; }
.cta__title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 600;
  letter-spacing: -.04em;
  line-height: 1.1;
  margin-bottom: 2rem;
}
.cta__actions { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }

/* ---------- contact / footer ---------- */
.contact { background: var(--ink); color: var(--cream); }
.contact__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(2.5rem, 7vw, 7rem);
  padding: clamp(4rem, 12vh, 8rem) var(--pad) clamp(3rem, 8vh, 5rem);
  max-width: 1200px;
  margin: 0 auto;
}
.contact__title {
  font-size: clamp(3.5rem, 9vw, 7.5rem);
  font-weight: 500;
  letter-spacing: -.055em;
  line-height: .95;
}
.contact__note { margin-top: 1.75rem; color: var(--muted-dark); font-size: .95rem; max-width: 24em; }

.form { display: flex; flex-direction: column; gap: 1.6rem; }
.field { display: flex; flex-direction: column; gap: .45rem; }
.field label {
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted-dark);
}
.field input,
.field textarea {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(243, 237, 227, .3);
  color: var(--cream);
  font: 400 1rem/1.5 "Inter", sans-serif;
  padding: .4rem 0 .65rem;
  resize: vertical;
  transition: border-color .25s;
}
.field input:focus,
.field textarea:focus { outline: none; border-color: var(--accent); }
.hp { position: absolute; left: -9999px; opacity: 0; }
.form__status { font-size: .85rem; min-height: 1.2em; }
.form__status--err { color: #e08b6d; }
.form__done { text-align: center; padding: 2rem 0; }
.form__done svg {
  width: 56px;
  height: 56px;
  margin-bottom: 1rem;
  fill: none;
  stroke: var(--accent);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.form__done strong { display: block; font-size: 1.15rem; letter-spacing: -.02em; }
.form__done span { color: var(--muted-dark); font-size: .9rem; }

.footer { border-top: 1px solid rgba(243, 237, 227, .12); padding: clamp(2.5rem, 6vh, 4rem) var(--pad) 2rem; }
.footer__mark { width: clamp(4rem, 10vw, 7rem); color: var(--accent); margin-bottom: 2.5rem; }
.footer__cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin-bottom: 3.5rem;
}
.footer__cols h3 {
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted-dark);
  margin-bottom: .9rem;
}
.footer__cols a,
.footer__cols p {
  display: block;
  color: var(--cream);
  text-decoration: none;
  font-size: .88rem;
  line-height: 1.9;
  opacity: .85;
}
.footer__cols a:hover { opacity: 1; color: var(--accent); }
.footer__base {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  font-size: .75rem;
  color: var(--muted-dark);
  border-top: 1px solid rgba(243, 237, 227, .12);
  padding-top: 1.5rem;
}

/* ---------- reveals ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1); }
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .marquee { transform: none !important; }
  .hero__streaks span,
  .hero__drive,
  .hero__beam,
  .hero__lamp,
  .hero__hubs g,
  .hero__dashes { animation: none !important; }
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .topbar__nav { display: none; }
  .about__inner { grid-template-columns: 1fr; }
  .about__portrait { max-width: 200px; }
  .approach__inner { grid-template-columns: 1fr; }
  .contact__inner { grid-template-columns: 1fr; }
}
