/* ============================================================
   Neuvis — computer-vision & video-analysis studio
   Light theme by default · dark theme via [data-theme="dark"]
   ============================================================ */
:root {
  /* light (default) */
  --bg:        #f5f5ef;
  --bg-2:      #ecede6;
  --surface:   #ffffff;
  --line:      #e0e0d5;
  --navy:      #2a1f4e;
  --teal:      #137a70;
  --teal-br:   #1c8c82;
  --teal-dim:  #4cb3a8;
  --ink:       #181327;
  --muted:     #565368;
  --faint:     #8b8898;
  --on-teal:   #ffffff;
  --grid:      rgba(42,31,78,.055);
  --glow:      radial-gradient(58% 48% at 74% -10%, rgba(28,140,130,.12), transparent 62%),
               radial-gradient(46% 40% at 6% 2%, rgba(42,31,78,.05), transparent 60%);
  --grain-op:  .025;
  --maxw:      1180px;
  color-scheme: light;

  --display: "Bricolage Grotesque", "Hanken Grotesk", sans-serif;
  --body:    "Hanken Grotesk", system-ui, sans-serif;
  --mono:    "JetBrains Mono", ui-monospace, monospace;
}
[data-theme="dark"] {
  --bg:        #0b0912;
  --bg-2:      #11101c;
  --surface:   #15131f;
  --line:      #272338;
  --navy:      #2a1f4e;
  --teal:      #1c8c82;
  --teal-br:   #34e0ce;
  --teal-dim:  #1a7a72;
  --ink:       #ecebf4;
  --muted:     #9b98ad;
  --faint:     #67637c;
  --on-teal:   #04130f;
  --grid:      rgba(150,150,190,.07);
  --glow:      radial-gradient(60% 50% at 70% -5%, rgba(52,224,206,.10), transparent 60%),
               radial-gradient(50% 40% at 10% 8%, rgba(42,31,78,.45), transparent 60%);
  --grain-op:  .04;
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background .35s ease, color .35s ease;
}
::selection { background: var(--teal); color: #fff; }

a { color: inherit; text-decoration: none; }
em { font-style: normal; color: var(--teal-br); }
strong { color: var(--ink); font-weight: 600; }

/* ---------- atmosphere ---------- */
.grid-bg {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 0%, transparent 75%);
          mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 0%, transparent 75%);
  opacity: .6;
}
body::before {
  content: ""; position: fixed; z-index: -2; inset: 0; pointer-events: none;
  background: var(--glow);
}
.grain {
  position: fixed; inset: -50%; z-index: -1; pointer-events: none; opacity: var(--grain-op);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 22px;
  max-width: var(--maxw); margin: 0 auto; padding: 18px 28px;
  backdrop-filter: blur(12px);
}
.nav::after {
  content: ""; position: absolute; left: 28px; right: 28px; bottom: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line) 20%, var(--line) 80%, transparent);
}
.nav__brand { display: flex; align-items: center; gap: 11px; }
.nav__mark { display: block; }
.nav__name { font-family: var(--display); font-weight: 700; letter-spacing: .14em; font-size: 18px; }
.nav__links { display: flex; gap: 26px; margin-left: auto; font-size: 14.5px; color: var(--muted); }
.nav__links a { position: relative; transition: color .2s; }
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: -5px; height: 1px; width: 0;
  background: var(--teal-br); transition: width .25s;
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { width: 100%; }
.nav__menu { display: none; background: none; border: 0; color: var(--ink); font-size: 26px; cursor: pointer; }

/* theme toggle */
.theme {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 2px;
  color: var(--ink); cursor: pointer; font-size: 16px; line-height: 1;
  transition: border-color .2s, color .2s, transform .2s;
}
.theme:hover { border-color: var(--teal); color: var(--teal-br); transform: translateY(-1px); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--mono); font-size: 13.5px; letter-spacing: .02em;
  padding: 12px 20px; border-radius: 2px; border: 1px solid var(--line);
  transition: transform .2s, background .2s, border-color .2s, color .2s;
  white-space: nowrap; cursor: pointer;
}
.btn .arrow { transition: transform .2s; font-style: normal; }
.btn:hover .arrow { transform: translate(2px,-2px); }
.btn--ghost { background: var(--surface); }
.btn--ghost:hover { border-color: var(--teal); color: var(--teal-br); }
.btn--solid { background: var(--teal); color: var(--on-teal); border-color: var(--teal); font-weight: 500; }
.btn--solid:hover { background: var(--teal-br); border-color: var(--teal-br); transform: translateY(-2px); }
.btn--lg { padding: 17px 28px; font-size: 16px; }

/* ---------- hero ---------- */
.hero { position: relative; max-width: var(--maxw); margin: 0 auto; padding: 116px 28px 90px; }
.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--mono); font-size: 13px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--teal); margin-bottom: 30px;
}
.hero__eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal-br); box-shadow: 0 0 0 4px rgba(28,140,130,.18); animation: pulse 2.4s infinite; }
@keyframes pulse { 0%,100%{ opacity: 1 } 50%{ opacity: .35 } }

.hero__title {
  font-family: var(--display); font-weight: 700; line-height: .92;
  font-size: clamp(3.3rem, 11vw, 8.4rem); letter-spacing: -.03em; margin-bottom: 30px;
}
.hero__title span { display: block; }
.hero__lede { max-width: 620px; font-size: clamp(1.05rem, 2.2vw, 1.32rem); color: var(--muted); margin-bottom: 38px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 54px; }
.hero__meta {
  display: flex; flex-wrap: wrap; gap: 14px 40px;
  font-family: var(--mono); font-size: 12.5px; color: var(--faint); letter-spacing: .03em;
  padding-top: 26px; border-top: 1px solid var(--line);
}
.hero__meta b { color: var(--teal); font-weight: 500; margin-right: 6px; }

.reticle { position: absolute; top: 96px; right: 30px; width: 250px; height: 250px; display: none; opacity: .9; }
@media (min-width: 1080px) { .reticle { display: block; } }
.reticle__b { position: absolute; width: 26px; height: 26px; border: 2px solid var(--teal-br); }
.reticle .tl { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.reticle .tr { top: 0; right: 0; border-left: 0; border-bottom: 0; }
.reticle .bl { bottom: 0; left: 0; border-right: 0; border-top: 0; }
.reticle .br { bottom: 0; right: 0; border-left: 0; border-top: 0; }
.reticle__label { position: absolute; top: -22px; left: 0; font-family: var(--mono); font-size: 11px; color: var(--teal-br); letter-spacing: .04em; background: var(--bg); padding: 0 6px; }
.reticle { animation: scan 6s ease-in-out infinite; }
@keyframes scan { 0%,100%{ transform: translateY(0) } 50%{ transform: translateY(18px) } }

/* ---------- marquee ---------- */
.marquee {
  border-block: 1px solid var(--line); overflow: hidden; padding: 18px 0;
  background: linear-gradient(180deg, transparent, rgba(28,140,130,.05));
}
.marquee__track { display: flex; gap: 26px; width: max-content; animation: slide 38s linear infinite; }
.marquee__track span { font-family: var(--display); font-size: 1.35rem; font-weight: 500; color: var(--muted); white-space: nowrap; }
.marquee__track i { color: var(--teal); font-style: normal; align-self: center; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
.section { max-width: var(--maxw); margin: 0 auto; padding: 110px 28px; }
.section__head { margin-bottom: 56px; }
.kicker { display: inline-block; font-family: var(--mono); font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--teal); margin-bottom: 18px; }
.section__title { font-family: var(--display); font-weight: 600; font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.02; letter-spacing: -.02em; }
.section__lede { color: var(--muted); max-width: 460px; margin-top: 18px; }

/* ---------- service cards ---------- */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.card {
  position: relative; background: var(--surface); border: 1px solid var(--line);
  padding: 34px 30px 30px; border-radius: 3px; overflow: hidden;
  transition: transform .3s, border-color .3s, box-shadow .3s;
}
.card::before, .card::after { content: ""; position: absolute; width: 14px; height: 14px; transition: all .3s; opacity: 0; }
.card::before { top: 12px; left: 12px; border-top: 2px solid var(--teal-br); border-left: 2px solid var(--teal-br); }
.card::after  { bottom: 12px; right: 12px; border-bottom: 2px solid var(--teal-br); border-right: 2px solid var(--teal-br); }
.card:hover { transform: translateY(-5px); border-color: var(--teal-dim); box-shadow: 0 18px 40px -24px rgba(28,140,130,.45); }
.card:hover::before, .card:hover::after { opacity: 1; }
.card__no { position: absolute; top: 24px; right: 26px; font-family: var(--mono); font-size: 13px; color: var(--faint); }
.card__icon { font-size: 32px; color: var(--teal-br); line-height: 1; margin-bottom: 22px; }
.card h3 { font-family: var(--display); font-weight: 600; font-size: 1.5rem; letter-spacing: -.01em; margin-bottom: 12px; }
.card p { color: var(--muted); font-size: 15.5px; margin-bottom: 20px; }
.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 7px; }
.tags li { font-family: var(--mono); font-size: 11.5px; color: var(--teal); border: 1px solid var(--line); padding: 4px 9px; border-radius: 2px; }

/* ---------- approach ---------- */
.section--split { display: grid; grid-template-columns: 1fr 1.05fr; gap: 60px; align-items: start; }
.section--split .section__head { margin-bottom: 0; position: sticky; top: 100px; }
.steps { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.step { display: flex; gap: 26px; padding: 30px 8px; border-top: 1px solid var(--line); }
.step:last-child { border-bottom: 1px solid var(--line); }
.step__no { font-family: var(--mono); font-size: 14px; color: var(--teal); padding-top: 5px; }
.step h3 { font-family: var(--display); font-weight: 600; font-size: 1.65rem; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 15.5px; }

/* ---------- about ---------- */
.section--about { display: grid; grid-template-columns: 1.3fr .7fr; gap: 60px; align-items: center; }
.about__lead { font-family: var(--display); font-weight: 500; font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.18; letter-spacing: -.015em; margin-bottom: 22px; }
.about p { color: var(--muted); }
.about__logo { display: flex; justify-content: center; }
.about__logo img { max-width: 100%; height: auto; filter: drop-shadow(0 18px 50px rgba(28,140,130,.18)); }

/* ---------- contact ---------- */
.contact {
  position: relative; max-width: 940px; margin: 60px auto 110px; padding: 86px 40px;
  text-align: center; border: 1px solid var(--line); border-radius: 4px;
  background: radial-gradient(70% 120% at 50% 0%, rgba(28,140,130,.12), transparent 70%), var(--bg-2);
}
.contact__title { font-family: var(--display); font-weight: 700; font-size: clamp(2.4rem, 6vw, 4.6rem); line-height: .98; letter-spacing: -.03em; margin: 6px 0 18px; }
.contact__lede { color: var(--muted); margin-bottom: 34px; }
.contact .reticle__b { width: 22px; height: 22px; }
.contact .tl { top: 16px; left: 16px; border-right: 0; border-bottom: 0; }
.contact .tr { top: 16px; right: 16px; border-left: 0; border-bottom: 0; }
.contact .bl { bottom: 16px; left: 16px; border-right: 0; border-top: 0; }
.contact .br { bottom: 16px; right: 16px; border-left: 0; border-top: 0; }

/* ---------- footer ---------- */
.footer {
  max-width: var(--maxw); margin: 0 auto; padding: 40px 28px 60px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 20px 40px; border-top: 1px solid var(--line);
}
.footer__brand { display: flex; align-items: center; gap: 11px; font-family: var(--mono); font-size: 13px; letter-spacing: .04em; color: var(--muted); }
.footer__links { display: flex; gap: 22px; font-size: 14px; color: var(--muted); }
.footer__links a:hover { color: var(--teal-br); }
.footer__legal { width: 100%; font-family: var(--mono); font-size: 12px; color: var(--faint); letter-spacing: .02em; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; transition-delay: calc(var(--d, 0) * 90ms); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .reticle, .hero__eyebrow .dot, .marquee__track { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .nav__links { display: none; }
  .nav__cta { display: none; }
  .nav__menu { display: block; }
  .theme { margin-left: auto; }
  .nav.open .nav__links {
    display: flex; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column;
    gap: 0; background: var(--bg-2); border-bottom: 1px solid var(--line);
  }
  .nav.open .nav__links a { padding: 16px 28px; border-top: 1px solid var(--line); }
  .cards { grid-template-columns: 1fr; }
  .section--split, .section--about { grid-template-columns: 1fr; gap: 36px; }
  .section--split .section__head { position: static; }
  .about__logo { order: -1; }
}
@media (max-width: 480px) {
  body { font-size: 16px; }
  .section { padding: 78px 22px; }
  .hero { padding: 80px 22px 70px; }
  .contact { padding: 60px 24px; margin-inline: 14px; }
}
