@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=IBM+Plex+Mono:wght@400;500&display=swap');

/* ─── Reset & Variables ────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:          #050505;
  --surface:     #0D0D0D;
  --surface-2:   #141414;
  --border:      rgba(255, 255, 255, 0.07);
  --border-2:    rgba(255, 255, 255, 0.12);
  --accent:      #E8622A;
  --accent-dim:  rgba(232, 98, 42, 0.12);
  --text:        #ECEBE7;
  --muted:       #5C5B58;
  --muted-2:     #8C8B87;
  --font-d:      'Syne', sans-serif;
  --font-m:      'IBM Plex Mono', monospace;
  --max:         1320px;
  --gutter:      clamp(1.5rem, 4vw, 3rem);
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-d);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  cursor: none;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ─── Custom Cursor ─────────────────────────────────────────────────── */
.cursor {
  position: fixed;
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.2s, height 0.2s, opacity 0.2s;
}
.cursor-ring {
  position: fixed;
  width: 36px; height: 36px;
  border: 1px solid rgba(232, 98, 42, 0.4);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.35s cubic-bezier(0.16,1,0.3,1),
              height 0.35s cubic-bezier(0.16,1,0.3,1),
              border-color 0.2s;
}
body:has(a:hover) .cursor-ring,
body:has(button:hover) .cursor-ring { width: 56px; height: 56px; border-color: var(--accent); }

/* ─── Grid Noise Background ─────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image:
    radial-gradient(circle at 20% 20%, rgba(232, 98, 42, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(232, 98, 42, 0.02) 0%, transparent 40%);
  pointer-events: none;
  z-index: 0;
}

/* ─── Navigation ─────────────────────────────────────────────────────── */
nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1.5rem var(--gutter);
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid transparent;
  transition: background 0.4s, border-color 0.4s;
}
nav.scrolled {
  background: rgba(5, 5, 5, 0.94);
  backdrop-filter: blur(12px);
  border-color: var(--border);
}

.nav-logo {
  font-family: var(--font-m);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text);
  display: flex; align-items: center; gap: 0.5rem;
}
.nav-logo span {
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
}

.nav-links {
  display: flex; align-items: center; gap: 2rem;
  list-style: none;
}
.nav-links a {
  font-size: 0.82rem;
  font-family: var(--font-m);
  color: var(--muted-2);
  letter-spacing: 0.03em;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.nav-cta {
  font-family: var(--font-m);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  padding: 0.55rem 1.25rem;
  background: var(--accent);
  color: #fff;
  border: none;
  cursor: none;
  transition: background 0.2s, transform 0.15s;
  text-transform: uppercase;
}
.nav-cta:hover { background: #d4561f; transform: translateY(-1px); }

/* ─── Hero ───────────────────────────────────────────────────────────── */
#hero {
  position: relative;
  min-height: 100svh;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: end;
  overflow: hidden;
}

.hero-grid-bg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, black, transparent);
}

.hero-eyebrow {
  position: absolute;
  top: 7rem;
  left: var(--gutter);
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: flex; align-items: center; gap: 0.75rem;
}
.hero-eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px; height: 1px;
  background: var(--accent);
}

.hero-counter {
  position: absolute;
  top: 7rem; right: var(--gutter);
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

.hero-headline {
  position: relative;
  padding-top: clamp(8rem, 14vw, 12rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

.hero-headline h1 {
  font-size: clamp(4rem, 11vw, 13rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  overflow: hidden;
}

.hero-headline h1 .line {
  display: block;
  overflow: hidden;
}

.hero-headline h1 .line-inner {
  display: block;
  transform: translateY(110%);
  transition: transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-headline h1 .line:nth-child(1) .line-inner { transition-delay: 0.1s; }
.hero-headline h1 .line:nth-child(2) .line-inner { transition-delay: 0.2s; }
.hero-headline h1 .line:nth-child(3) .line-inner { transition-delay: 0.3s; }

.hero-headline h1 .accent-word { color: var(--accent); }

.hero-loaded .hero-headline h1 .line-inner { transform: translateY(0); }

.hero-footer {
  padding-bottom: clamp(2rem, 4vw, 3.5rem);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
}

.hero-sub {
  max-width: 420px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s 0.65s, transform 0.8s cubic-bezier(0.16,1,0.3,1) 0.65s;
}
.hero-loaded .hero-sub { opacity: 1; transform: translateY(0); }

.hero-sub p {
  font-size: clamp(0.95rem, 1.3vw, 1.15rem);
  color: var(--muted-2);
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

.hero-actions {
  display: flex; gap: 1rem; flex-wrap: wrap;
}

.btn-primary {
  font-family: var(--font-m);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 0.85rem 1.75rem;
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  cursor: none;
  transition: background 0.2s, transform 0.15s;
  display: inline-flex; align-items: center; gap: 0.5rem;
}
.btn-primary:hover { background: #d4561f; transform: translateY(-2px); }

.btn-secondary {
  font-family: var(--font-m);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 0.85rem 1.75rem;
  background: transparent;
  color: var(--muted-2);
  border: 1px solid var(--border-2);
  cursor: none;
  transition: color 0.2s, border-color 0.2s, transform 0.15s;
  display: inline-flex; align-items: center; gap: 0.5rem;
}
.btn-secondary:hover { color: var(--text); border-color: var(--muted); transform: translateY(-2px); }

.hero-stats {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s 0.8s, transform 0.8s cubic-bezier(0.16,1,0.3,1) 0.8s;
  display: flex; gap: 2.5rem;
}
.hero-loaded .hero-stats { opacity: 1; transform: translateY(0); }

.stat-item { text-align: right; }
.stat-value {
  display: block;
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
}
.stat-value .accent { color: var(--accent); }
.stat-label {
  display: block;
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 0.3rem;
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem; left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  opacity: 0;
  animation: fadeIn 1s 1.2s forwards;
}
.scroll-indicator span {
  font-family: var(--font-m);
  font-size: 0.65rem;
  color: var(--muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.scroll-line {
  width: 1px; height: 40px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ─── Section Shared ─────────────────────────────────────────────────── */
section {
  position: relative;
  padding: clamp(4rem, 8vw, 8rem) var(--gutter);
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin: 0 auto;
}

.section-label {
  display: flex; align-items: center; gap: 0.75rem;
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 3rem;
}
.section-label::before {
  content: '';
  display: inline-block;
  width: 20px; height: 1px;
  background: var(--accent);
}

/* ─── Services ───────────────────────────────────────────────────────── */
#services { border-top: 1px solid var(--border); }

.services-header {
  display: flex; align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 4rem;
  flex-wrap: wrap;
}

.services-header h2 {
  font-size: clamp(2.5rem, 5vw, 5rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}

.services-header p {
  max-width: 300px;
  font-size: 0.9rem;
  color: var(--muted-2);
  line-height: 1.7;
  text-align: right;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}

.service-card {
  position: relative;
  background: var(--bg);
  padding: 2.5rem 2rem;
  display: flex; flex-direction: column;
  overflow: hidden;
  cursor: none;
  transition: background 0.3s;
}
.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.service-card:hover { background: var(--surface); }
.service-card:hover::before { transform: scaleX(1); }

.service-index {
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  margin-bottom: 2.5rem;
}

.service-icon {
  width: 40px; height: 40px;
  margin-bottom: 1.5rem;
  color: var(--accent);
  opacity: 0.8;
}

.service-card h3 {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.service-card p {
  font-size: 0.875rem;
  color: var(--muted-2);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 2rem;
}

.service-tags {
  display: flex; flex-wrap: wrap; gap: 0.4rem;
  margin-bottom: 2rem;
}
.service-tag {
  font-family: var(--font-m);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.6rem;
  background: var(--surface-2);
  color: var(--muted-2);
  border: 1px solid var(--border);
  text-transform: uppercase;
}

.service-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--font-m);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  transition: gap 0.25s;
}
.service-link:hover { gap: 0.85rem; }
.service-link svg { width: 14px; height: 14px; transition: transform 0.25s; }
.service-link:hover svg { transform: translateX(3px); }

/* ─── Approach ───────────────────────────────────────────────────────── */
#approach {
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
  align-items: start;
}

.approach-left h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  position: sticky; top: 8rem;
}

.approach-steps { display: flex; flex-direction: column; }

.step {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 1.5rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
  opacity: 0.45;
  transition: opacity 0.3s;
}
.step:first-child { border-top: 1px solid var(--border); }
.step:hover { opacity: 1; }

.step-num {
  font-family: var(--font-m);
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  padding-top: 0.2rem;
}

.step-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}
.step-content p {
  font-size: 0.875rem;
  color: var(--muted-2);
  line-height: 1.7;
}

/* ─── About ──────────────────────────────────────────────────────────── */
#about {
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}

.about-text {}

.about-text h2 {
  font-size: clamp(2.5rem, 4.5vw, 4rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.about-text h2 em {
  font-style: normal;
  color: var(--accent);
}

.about-text p {
  font-size: 1rem;
  color: var(--muted-2);
  line-height: 1.75;
  margin-bottom: 1rem;
}
.about-text p strong { color: var(--text); font-weight: 600; }

.about-founders {
  display: flex; flex-direction: column; gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  margin-top: 2.5rem;
}

.founder {
  background: var(--bg);
  padding: 1.25rem 1.5rem;
  display: flex; align-items: center; gap: 1.25rem;
  transition: background 0.2s;
}
.founder:hover { background: var(--surface); }

.founder-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--border-2);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-m);
  font-size: 0.8rem;
  color: var(--accent);
  flex-shrink: 0;
}
.founder-info {}
.founder-name {
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.founder-role {
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.about-visual {
  position: relative;
}

.about-terminal {
  background: var(--surface);
  border: 1px solid var(--border);
  font-family: var(--font-m);
  font-size: 0.82rem;
  line-height: 1.8;
  color: var(--muted-2);
  padding: 1.5rem;
}
.terminal-bar {
  display: flex; align-items: center; gap: 0.5rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.t-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
}
.t-dot.red { background: #FF5F57; }
.t-dot.yellow { background: #FFBD2E; }
.t-dot.green { background: #28C840; }
.terminal-bar span {
  font-size: 0.68rem;
  color: var(--muted);
  margin-left: auto;
}
.t-line { display: block; }
.t-prompt { color: var(--accent); }
.t-cmd { color: var(--text); }
.t-comment { color: var(--muted); }
.t-output { color: #5CB85C; }
.t-cursor {
  display: inline-block;
  width: 8px; height: 1em;
  background: var(--accent);
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

.about-accent-bar {
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  margin-bottom: 0;
}

/* ─── Clients / Proof ────────────────────────────────────────────────── */
#proof {
  border-top: 1px solid var(--border);
  padding-top: 3rem;
  padding-bottom: 3rem;
}
.proof-inner {
  display: flex; align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.proof-text {
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.proof-items {
  display: flex; align-items: center; gap: 2.5rem;
  flex-wrap: wrap;
}
.proof-item {
  font-family: var(--font-d);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.02em;
  transition: color 0.2s;
}
.proof-item:hover { color: var(--text); }

/* ─── CTA ────────────────────────────────────────────────────────────── */
#cta {
  border-top: 1px solid var(--border);
  text-align: center;
  padding: clamp(5rem, 10vw, 10rem) var(--gutter);
}

.cta-pre {
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  display: flex; align-items: center; justify-content: center; gap: 0.75rem;
}
.cta-pre::before, .cta-pre::after {
  content: '';
  display: inline-block;
  width: 30px; height: 1px;
  background: var(--accent);
}

#cta h2 {
  font-size: clamp(3rem, 8vw, 9rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin-bottom: 2rem;
}

#cta p {
  font-size: 1.05rem;
  color: var(--muted-2);
  max-width: 480px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

.cta-email {
  display: inline-flex; align-items: center; gap: 0.75rem;
  font-family: var(--font-m);
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  color: var(--text);
  border-bottom: 1px solid var(--accent);
  padding-bottom: 0.15rem;
  transition: color 0.2s, gap 0.25s;
}
.cta-email:hover { color: var(--accent); gap: 1rem; }
.cta-email svg { width: 14px; height: 14px; }

/* ─── Footer ─────────────────────────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem var(--gutter);
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-logo {
  font-family: var(--font-m);
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.footer-links {
  display: flex; gap: 1.5rem;
  list-style: none;
}
.footer-links a {
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--accent); }

.footer-copy {
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ─── Scroll Reveal ──────────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ─── Inner Page Shared ──────────────────────────────────────────────── */
.inner-hero {
  padding-top: 9rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid var(--border);
}

.inner-hero .section-label { margin-bottom: 1.5rem; }

.inner-hero h1 {
  font-size: clamp(3rem, 7vw, 7rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.inner-hero p {
  font-size: 1.1rem;
  color: var(--muted-2);
  max-width: 560px;
  line-height: 1.7;
}

@keyframes fadeIn { to { opacity: 1; } }

/* ─── Responsive ─────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .services-grid { grid-template-columns: 1fr; }
  #approach { grid-template-columns: 1fr; }
  .approach-left h2 { position: static; margin-bottom: 2rem; }
  #about { grid-template-columns: 1fr; gap: 3rem; }
}

@media (max-width: 640px) {
  .hero-footer { flex-direction: column; align-items: flex-start; }
  .hero-stats { align-self: flex-start; }
  .stat-item { text-align: left; }
  .nav-links { display: none; }
  body { cursor: auto; }
  .cursor, .cursor-ring { display: none; }
}