:root {
  --bg: #07090d;
  --bg-2: #0d121b;
  --ink: #e9eef5;
  --muted: #8a95a8;
  --line: rgba(233, 238, 245, 0.12);
  --copper: #f0905a;
  --copper-2: #c8653a;
  --ice: #6fb6ff;
  --ice-2: #3c7bd6;
  --glow: 0 0 40px rgba(240, 144, 90, 0.35), 0 0 80px rgba(111, 182, 255, 0.2);
  --font: "Space Grotesk", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  background: transparent; /* html carries the color so the fixed vortex canvas shows through */
  color: var(--ink);
  font-family: var(--font);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body.loading { overflow: hidden; }
a { color: inherit; text-decoration: none; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
em { font-style: normal; background: linear-gradient(90deg, var(--copper), var(--ice)); -webkit-background-clip: text; background-clip: text; color: transparent; }
::selection { background: var(--copper); color: var(--bg); }


/* ---------- Loader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center; align-content: center; gap: 14px;
  pointer-events: all;
}
.loader__curtain { position: absolute; left: 0; right: 0; height: 50%; background: var(--bg); z-index: -1; }
.loader__curtain--top { top: 0; }
.loader__curtain--bottom { bottom: 0; }
.loader__mark { width: 96px; height: 96px; animation: strike 0.9s var(--ease) infinite alternate; filter: drop-shadow(0 0 20px rgba(240, 144, 90, 0.5)); }
@keyframes strike { from { transform: rotate(-18deg) translateY(-6px); } to { transform: rotate(8deg) translateY(4px); } }
.loader__count { font-family: var(--mono); font-size: 44px; font-weight: 500; letter-spacing: 0.05em; }
.loader__label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Global layers ---------- */
.bg-vortex { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: -2; display: block; }
.grain {
  position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: 0.07;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 0.6s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-5%, 3%); } 40% { transform: translate(3%, -6%); }
  60% { transform: translate(-7%, 2%); } 80% { transform: translate(4%, 5%); } 100% { transform: translate(0, 0); }
}
.progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 100%; z-index: 80;
  background: linear-gradient(90deg, var(--copper), var(--ice));
  transform-origin: 0 50%; transform: scaleX(0);
  box-shadow: 0 0 12px var(--copper);
}

/* ---------- Cursor ---------- */
.cursor-ring { position: fixed; top: 0; left: 0; z-index: 95; pointer-events: none; border-radius: 50%; }
.cursor-ring {
  width: 38px; height: 38px; margin: -19px 0 0 -19px;
  border: 1px solid rgba(233, 238, 245, 0.5);
  display: grid; place-items: center;
  transition: width 0.35s var(--ease), height 0.35s var(--ease), margin 0.35s var(--ease), background 0.35s, border-color 0.35s;
}
.cursor-ring span { font-family: var(--mono); font-size: 10px; letter-spacing: 0.15em; text-transform: uppercase; color: var(--bg); opacity: 0; transition: opacity 0.2s; }
.cursor-ring.is-hover { width: 70px; height: 70px; margin: -35px 0 0 -35px; border-color: var(--copper); background: rgba(240, 144, 90, 0.12); }
.cursor-ring.is-label { width: 84px; height: 84px; margin: -42px 0 0 -42px; background: var(--copper); border-color: var(--copper); }
.cursor-ring.is-label span { opacity: 1; }
@media (hover: none), (pointer: coarse) { .cursor-ring { display: none; } }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 70;
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px clamp(16px, 4vw, 48px);
  mix-blend-mode: difference;
}
.nav__brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: 0.18em; font-size: 14px; }
.nav__brand img { width: 32px; height: 32px; }
.nav__brand b { font-weight: 700; }
.nav__links { display: flex; gap: 32px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; }
.nav__links a { position: relative; }
.nav__links a::after { content: ""; position: absolute; left: 0; bottom: -4px; height: 1px; width: 100%; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform 0.4s var(--ease); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__clock { display: flex; align-items: center; gap: 8px; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: #5cff9d; box-shadow: 0 0 10px #5cff9d; animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { opacity: 0.3; } }
@media (max-width: 720px) { .nav__links, .nav__clock { display: none; } }

/* ---------- Hero ---------- */
.hero {
  height: 100svh; min-height: 560px; position: relative; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  padding: 0 16px 6vh; text-align: center;
}
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hero__flash { position: absolute; inset: 0; background: radial-gradient(circle at 50% 62%, #fff, #ffd2a8 30%, rgba(240, 144, 90, 0) 70%); opacity: 0; pointer-events: none; z-index: 3; mix-blend-mode: screen; }
.hero__chips { position: absolute; inset: 0; pointer-events: none; z-index: 4; }
.sol-chip {
  --accent: var(--copper);
  position: absolute; left: 0; top: 0; pointer-events: auto; opacity: 0;
  display: inline-flex; align-items: center; gap: 10px; padding: 9px 16px 9px 12px; border-radius: 999px;
  font: 500 14px var(--font); color: var(--ink); white-space: nowrap; cursor: pointer;
  background: rgba(10, 14, 22, 0.55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow: 0 0 24px color-mix(in srgb, var(--accent) 30%, transparent);
  transition: background 0.3s, box-shadow 0.3s;
}
.sol-chip:hover { background: color-mix(in srgb, var(--accent) 30%, rgba(10, 14, 22, 0.8)); box-shadow: 0 0 40px color-mix(in srgb, var(--accent) 60%, transparent); }
.sol-chip i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.sol-chip__n { font-family: var(--mono); font-size: 10px; color: var(--muted); }
@media (max-width: 720px) { .sol-chip { font-size: 12px; padding: 7px 12px 7px 10px; } .sol-chip__n { display: none; } }
.hero__content { position: relative; z-index: 5; display: flex; flex-direction: column; align-items: center; pointer-events: none; }
.hero__content a, .hero__content .ch { pointer-events: auto; }
.hero.glitch .hero__canvas { animation: glitch 0.52s steps(2) both; }
@keyframes glitch {
  0% { transform: translate(-6px, 3px); filter: drop-shadow(5px 0 0 rgba(255, 60, 90, 0.7)) drop-shadow(-5px 0 0 rgba(60, 200, 255, 0.7)) brightness(1.6); }
  20% { transform: translate(5px, -4px); filter: drop-shadow(-4px 0 0 rgba(255, 60, 90, 0.6)) drop-shadow(4px 0 0 rgba(60, 200, 255, 0.6)); clip-path: inset(10% 0 30% 0); }
  40% { transform: translate(-3px, 2px); clip-path: inset(50% 0 5% 0); }
  60% { transform: translate(2px, 0); filter: drop-shadow(2px 0 0 rgba(255, 60, 90, 0.4)) drop-shadow(-2px 0 0 rgba(60, 200, 255, 0.4)); clip-path: none; }
  100% { transform: none; filter: none; }
}
.skip { position: absolute; right: clamp(16px, 4vw, 48px); bottom: 28px; z-index: 6; background: none; border: 1px solid var(--line); color: var(--muted); padding: 8px 14px; border-radius: 999px; cursor: pointer; }
.skip:hover { color: var(--ink); border-color: var(--copper); }

.hero__title {
  font-size: clamp(32px, min(11vw, 15vh), 180px); font-weight: 700; letter-spacing: -0.04em; line-height: 0.9; white-space: nowrap;
  position: relative; z-index: 2;
}
.split { display: inline-block; }
.split .ch { display: inline-block; will-change: transform; }
.hero__title .ch {
  background: linear-gradient(180deg, #fff 30%, #9aa6b8 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: filter 0.5s;
}
.hero__title .ch:hover { filter: drop-shadow(0 0 22px rgba(240, 144, 90, 0.8)); }
.hero__sub { max-width: 560px; margin-top: 14px; color: var(--muted); font-size: clamp(15px, 1.4vw, 18px); line-height: 1.55; }
.hero__sub .mono { display: block; color: var(--copper); margin-bottom: 8px; }
.hero__cta { display: flex; gap: 14px; margin-top: 24px; flex-wrap: wrap; justify-content: center; }

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; padding: 16px 28px; border-radius: 999px;
  border: 1px solid var(--line); overflow: hidden; font-size: 15px; font-weight: 500;
  backdrop-filter: blur(8px); background: rgba(255, 255, 255, 0.03);
}
.btn span { position: relative; z-index: 1; transition: color 0.4s; }
.btn::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: linear-gradient(90deg, var(--copper), var(--ice));
  transform: translateY(101%); transition: transform 0.5s var(--ease);
}
.btn:hover::before { transform: translateY(0); }
.btn:hover span { color: var(--bg); }
.btn--solid { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ---------- Marquee ---------- */
.marquee { padding: 3vh 0; border-block: 1px solid var(--line); overflow: hidden; background: rgba(7, 9, 13, 0.6); backdrop-filter: blur(6px); }
.marquee__track { display: flex; align-items: center; gap: 2vw; width: max-content; white-space: nowrap; will-change: transform; }
.marquee__track span { font-size: clamp(20px, 3.5vw, 55px); font-weight: 700; letter-spacing: -0.03em; }
.marquee__track .outline { color: transparent; -webkit-text-stroke: 1px rgba(233, 238, 245, 0.6); }
.marquee__track i { font-style: normal; color: var(--copper); font-size: clamp(12px, 1.5vw, 22px); }

/* ---------- Sections ---------- */
.section-head { padding: 0 clamp(16px, 5vw, 64px); margin-bottom: 7vh; }
.eyebrow { color: var(--copper); display: inline-block; margin-bottom: 18px; }
h2 { font-size: clamp(42px, 7vw, 108px); line-height: 0.95; letter-spacing: -0.035em; font-weight: 700; }
.line-wrap { display: block; overflow: hidden; padding-bottom: 0.06em; }
.line-wrap > span { display: inline-block; }

.solutions { padding: 16vh 0 12vh; position: relative; background: linear-gradient(transparent, var(--bg) 18%); }
.cards {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 22px;
  padding: 0 clamp(16px, 5vw, 64px); perspective: 1400px;
}
.card { grid-column: span 2; }
.card:nth-child(-n+2) { grid-column: span 3; }
@media (max-width: 1080px) { .cards { grid-template-columns: repeat(2, 1fr); } .card, .card:nth-child(-n+2) { grid-column: span 1; } .card:last-child { grid-column: span 2; } }
@media (max-width: 720px) { .cards { grid-template-columns: 1fr; } .card:last-child { grid-column: span 1; } }
.section-lead { color: var(--muted); font-size: 18px; margin-top: 18px; max-width: 520px; }
.card__case { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; display: block; }
.linkish { background: none; border: 0; color: inherit; cursor: pointer; padding: 0; }
.card {
  --mx: 50%; --my: 50%; --accent: var(--copper);
  position: relative; min-height: 420px; border-radius: 22px; padding: 30px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01));
  border: 1px solid var(--line);
  display: flex; flex-direction: column; justify-content: space-between;
  overflow: hidden; transform-style: preserve-3d; transition: border-color 0.4s;
  isolation: isolate;
}
.card::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(500px circle at var(--mx) var(--my), color-mix(in srgb, var(--accent) 28%, transparent), transparent 45%);
  opacity: 0; transition: opacity 0.4s;
}
.card::after {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; z-index: 1; pointer-events: none;
  background: conic-gradient(from var(--angle, 0deg), transparent 0 70%, var(--accent), transparent);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.4s; animation: rotateBorder 4s linear infinite;
}
.card:hover::before, .card:hover::after { opacity: 1; }
@property --angle { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
@keyframes rotateBorder { to { --angle: 360deg; } }
.card__top { display: flex; justify-content: space-between; align-items: flex-start; transform: translateZ(40px); }
.card__index { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.chip { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); display: inline-flex; align-items: center; gap: 8px; }
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.card__glyph { position: absolute; right: -40px; top: 50%; width: 300px; height: 300px; transform: translateY(-50%) translateZ(10px); opacity: 0.55; pointer-events: none; }
.card__body { transform: translateZ(60px); position: relative; }
.card h3 { font-size: clamp(34px, 4vw, 56px); letter-spacing: -0.03em; line-height: 1; margin-bottom: 12px; }
.card p { color: var(--muted); max-width: 380px; line-height: 1.55; }
.card__tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.card__tags span { font-family: var(--mono); font-size: 11px; padding: 5px 10px; border-radius: 6px; background: rgba(255, 255, 255, 0.05); color: var(--ink); }
.card__link { position: absolute; right: 30px; bottom: 30px; width: 54px; height: 54px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; transition: background 0.4s, transform 0.4s var(--ease), color 0.4s; transform: translateZ(70px); }
.card:hover .card__link { background: var(--accent); color: var(--bg); transform: translateZ(70px) rotate(-45deg); }

/* ---------- Forge ---------- */
.forge { height: 320vh; position: relative; }
.forge__sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.forge__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.forge__text { position: absolute; left: clamp(16px, 5vw, 64px); top: 50%; transform: translateY(-50%); width: min(440px, calc(100vw - 32px)); z-index: 2; }
.forge__steps { position: relative; height: 240px; }
.step { position: absolute; inset: 0; opacity: 0; transform: translateY(40px); filter: blur(10px); }
.step b { font-family: var(--mono); color: var(--ice); font-weight: 400; font-size: 13px; }
.step h3 { font-size: clamp(56px, 8vw, 120px); letter-spacing: -0.04em; line-height: 1; margin: 6px 0 14px; }
.step p { color: var(--muted); font-size: 17px; line-height: 1.55; max-width: 360px; }
.forge__stats { position: absolute; right: clamp(16px, 5vw, 64px); bottom: 8vh; display: flex; gap: 48px; z-index: 2; text-align: right; }
.forge__stats div { display: flex; flex-direction: column; gap: 6px; }
.stat { font-size: clamp(40px, 5vw, 72px); font-weight: 700; letter-spacing: -0.04em; }
.forge__stats small { color: var(--muted); font-size: 10px; }
@media (max-width: 720px) {
  .forge__text { top: 18%; transform: none; }
  .forge__stats { gap: 22px; left: 16px; right: 16px; justify-content: space-between; text-align: left; }
}

/* ---------- Helix ---------- */
.helix { position: relative; min-height: 130vh; display: flex; align-items: center; padding: 10vh clamp(16px, 5vw, 64px); overflow: hidden; }
.helix canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.helix__copy { position: relative; z-index: 2; max-width: 560px; }
.helix__copy p { color: var(--muted); font-size: 18px; line-height: 1.6; margin-top: 26px; }

/* ---------- Footer ---------- */
.footer { padding: 14vh clamp(16px, 5vw, 64px) 30px; border-top: 1px solid var(--line); background: var(--bg); position: relative; overflow: hidden; }
.footer__big {
  font-size: 14.2vw; font-weight: 700; letter-spacing: -0.06em; line-height: 0.8; white-space: nowrap;
  color: transparent; -webkit-text-stroke: 1px rgba(233, 238, 245, 0.25);
  background: radial-gradient(260px circle at var(--fx, -500px) var(--fy, -500px), var(--copper), var(--ice) 40%, transparent 60%);
  -webkit-background-clip: text; background-clip: text;
  margin-left: -0.04em;
}
.footer__row { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 40px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
