/* ============================================
   PageFlow — Premium Design System v2
   Features: Custom cursor, 3D tilt cards, floating
   code snippets, animated borders, bento grid,
   horizontal scroll, mock UI, particles
   ============================================ */

:root {
  --color-primary: #6366f1;
  --color-primary-dark: #4f46e5;
  --color-primary-light: #818cf8;
  --color-secondary: #8b5cf6;
  --color-accent: #06b6d4;
  --color-dark: #0a0e1a;
  --color-dark-alt: #111827;
  --color-surface: #1a1f35;
  --color-light: #f8fafc;
  --color-white: #ffffff;
  --color-text: #1e293b;
  --color-text-muted: #64748b;
  --color-text-light: #94a3b8;
  --color-text-on-dark: #e2e8f0;
  --color-border: #e2e8f0;
  --gradient-primary: linear-gradient(135deg, #6366f1, #8b5cf6, #06b6d4);
  --gradient-primary-subtle: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(139,92,246,0.08));
  --gradient-cta: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  --gradient-dark: linear-gradient(180deg, #0a0e1a 0%, #1a1f35 100%);
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  /* Font sizes */
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 2rem;
  --font-size-4xl: 2.5rem;
  --font-size-5xl: 3rem;
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 5rem;
  --space-5xl: 7rem;
  /* Radii */
  --radius-sm: 0.375rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-2xl: 2rem;
  --radius-full: 9999px;
  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.1);
  --shadow-glow: 0 0 60px rgba(99, 102, 241, 0.2);
  --transition-fast: 150ms ease;
  --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
  --z-nav: 1000;
}

/* ============================================
   RESET
   ============================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-family);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { border: none; background: none; cursor: pointer; font-family: inherit; }
input, textarea { font-family: inherit; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.gradient-text { background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.gradient-text-light { background: linear-gradient(135deg, #fff 0%, #c7d2fe 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* Custom cursor removed for performance */

/* ============================================
   SECTION UTILITIES
   ============================================ */
.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
  padding: 0.4rem 1rem;
  background: rgba(99, 102, 241, 0.08);
  border-radius: var(--radius-full);
  border: 1px solid rgba(99, 102, 241, 0.15);
}
.section-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--color-text);
  margin-bottom: 1.25rem;
  letter-spacing: -0.03em;
}
.section-desc { font-size: 1.1rem; color: var(--color-text-muted); max-width: 560px; margin: 0 auto; line-height: 1.7; }
.section-header { text-align: center; margin-bottom: 4rem; }

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-weight: 600; font-size: 0.875rem;
  border-radius: var(--radius-full);
  padding: 0.75rem 1.5rem;
  transition: all var(--transition-base);
  position: relative; overflow: hidden;
}
.btn--primary { background: var(--gradient-cta); color: #fff; box-shadow: 0 4px 20px rgba(99,102,241,0.3); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(99,102,241,0.4); }
.btn--glow::after {
  content: ''; position: absolute; inset: -2px;
  background: var(--gradient-primary); border-radius: inherit;
  z-index: -1; opacity: 0; filter: blur(12px);
  transition: opacity 0.4s;
}
.btn--glow:hover::after { opacity: 0.6; }
.btn--ghost { color: var(--color-text-on-dark); border: 1px solid rgba(255,255,255,0.15); backdrop-filter: blur(4px); }
.btn--ghost:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.3); }
.btn--white { background: #fff; color: var(--color-primary-dark); box-shadow: 0 4px 20px rgba(0,0,0,0.1); }
.btn--white:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(0,0,0,0.15); }
.btn--lg { padding: 1rem 2rem; font-size: 1rem; }
.btn--xl { padding: 1.25rem 2.5rem; font-size: 1.1rem; }
.btn--full { width: 100%; justify-content: center; }

/* ============================================
   NAVIGATION
   ============================================ */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: var(--z-nav); padding: 0.5rem 0; transition: all var(--transition-base); }
.nav--scrolled { padding: 0.5rem 0; background: rgba(10,14,26,0.9); backdrop-filter: blur(20px) saturate(180%); border-bottom: 1px solid rgba(255,255,255,0.05); }
.nav__container { display: flex; align-items: center; justify-content: space-between; max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.nav__logo { display: flex; align-items: center; gap: 0.5rem; }
.nav__logo-img { width: 36px; height: 36px; border-radius: var(--radius-sm); }
.nav__logo-text { font-size: 1.2rem; font-weight: 700; color: #fff; }
.nav__menu { display: flex; align-items: center; gap: 2rem; }
.nav__list { display: flex; align-items: center; gap: 1.75rem; }
.nav__link { font-size: 0.875rem; font-weight: 500; color: var(--color-text-light); transition: color var(--transition-fast); position: relative; }
.nav__link::after { content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px; background: var(--gradient-primary); border-radius: var(--radius-full); transition: width var(--transition-base); }
.nav__link:hover { color: #fff; }
.nav__link:hover::after { width: 100%; }
.nav__cta { padding: 0.5rem 1.1rem; font-size: 0.8rem; }

/* Dropdown */
.nav__item--dropdown { position: relative; }
.nav__item--dropdown > .nav__link { display: flex; align-items: center; gap: 4px; }
.nav__item--dropdown > .nav__link svg { transition: transform var(--transition-fast); }
.nav__item--dropdown:hover > .nav__link svg { transform: rotate(180deg); }
.nav__dropdown { position: absolute; top: 100%; left: 50%; transform: translateX(-50%) translateY(8px); min-width: 180px; background: rgba(15, 20, 40, 0.95); backdrop-filter: blur(20px); border: 1px solid rgba(255,255,255,0.08); border-radius: var(--radius-lg); padding: 0.5rem; list-style: none; opacity: 0; visibility: hidden; pointer-events: none; transition: all var(--transition-base); box-shadow: 0 12px 40px rgba(0,0,0,0.3); padding-top: 1rem; }
.nav__dropdown::before { content: ''; position: absolute; top: -12px; left: 0; right: 0; height: 12px; }
.nav__item--dropdown:hover .nav__dropdown { opacity: 1; visibility: visible; pointer-events: auto; transform: translateX(-50%) translateY(0); }
.nav__dropdown li a { display: block; padding: 0.55rem 0.9rem; font-size: 0.82rem; font-weight: 500; color: var(--color-text-light); border-radius: var(--radius-sm); transition: all var(--transition-fast); text-decoration: none; }
.nav__dropdown li a:hover { color: #fff; background: rgba(99,102,241,0.15); }
.nav__dropdown-divider { height: 1px; margin: 0.35rem 0.5rem; background: rgba(255,255,255,0.08); }

.nav__toggle { display: none; flex-direction: column; gap: 5px; padding: 0.5rem; z-index: 1001; }
.nav__toggle span { display: block; width: 24px; height: 2px; background: #fff; border-radius: 2px; transition: all var(--transition-base); }
.nav__toggle--active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav__toggle--active span:nth-child(2) { opacity: 0; }
.nav__toggle--active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  background: var(--color-dark); overflow: hidden; padding: 7rem 0 4rem;
}
.hero__gradient-bg {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(99,102,241,0.15) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 30%, rgba(139,92,246,0.1) 0%, transparent 40%),
              radial-gradient(ellipse at 50% 80%, rgba(6,182,212,0.08) 0%, transparent 40%);
  transition: background 0.3s;
}
.hero__grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

/* Floating code snippets */
.hero__floating-elements { position: absolute; inset: 0; pointer-events: none; }
.floating-code {
  position: absolute; background: rgba(15,20,40,0.85); backdrop-filter: blur(10px);
  border: 1px solid rgba(99,102,241,0.2); border-radius: var(--radius-lg);
  padding: 1rem 1.25rem; font-family: var(--font-mono); font-size: 0.75rem;
  line-height: 1.6; color: var(--color-text-light);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.05);
  animation: floatCode 20s ease-in-out infinite;
  opacity: 0.7;
}
.floating-code--1 { top: 12%; right: 6%; animation-delay: 0s; }
.floating-code--2 { top: 60%; left: 4%; animation-delay: -7s; }
.floating-code--3 { bottom: 15%; right: 4%; animation-delay: -14s; }
.code-keyword { color: #c084fc; }
.code-function { color: #67e8f9; }
.code-string { color: #86efac; }
.code-prop { color: #fbbf24; }
.code-comment { color: #64748b; }

@keyframes floatCode {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-15px) rotate(0.5deg); }
  50% { transform: translateY(10px) rotate(-0.3deg); }
  75% { transform: translateY(-8px) rotate(0.2deg); }
}

/* Animated shapes */
.hero__shapes { position: absolute; inset: 0; pointer-events: none; }
.hero__shape {
  position: absolute; border-radius: 50%;
  border: 1px solid rgba(99,102,241,0.15);
  animation: morphShape 25s ease-in-out infinite;
}
.hero__shape--1 { width: 300px; height: 300px; top: 10%; left: -5%; animation-delay: 0s; border-color: rgba(99,102,241,0.1); }
.hero__shape--2 { width: 200px; height: 200px; bottom: 15%; right: 10%; animation-delay: -5s; border-color: rgba(6,182,212,0.15); }
.hero__shape--3 { width: 150px; height: 150px; top: 30%; right: 25%; animation-delay: -10s; border-color: rgba(139,92,246,0.12); }
.hero__shape--4 { width: 100px; height: 100px; bottom: 30%; left: 15%; animation-delay: -15s; border-color: rgba(99,102,241,0.1); }

@keyframes morphShape {
  0%, 100% { transform: scale(1) rotate(0deg); border-radius: 50%; }
  25% { transform: scale(1.1) rotate(90deg); border-radius: 40% 60% 50% 50%; }
  50% { transform: scale(0.95) rotate(180deg); border-radius: 50% 40% 60% 50%; }
  75% { transform: scale(1.05) rotate(270deg); border-radius: 60% 50% 40% 50%; }
}

.hero__content { position: relative; z-index: 2; max-width: 720px; margin: 0 auto; text-align: center; }
.hero__badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem; background: rgba(99,102,241,0.08);
  border: 1px solid rgba(99,102,241,0.2); border-radius: var(--radius-full);
  font-size: 0.85rem; font-weight: 500; color: var(--color-primary-light);
  margin-bottom: 2rem;
}
.hero__badge-dot { width: 8px; height: 8px; background: #22c55e; border-radius: 50%; animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34,197,94,0.4); } 50% { opacity: 0.8; box-shadow: 0 0 0 8px rgba(34,197,94,0); } }

.hero__title { font-size: clamp(2.5rem, 6vw, 4.2rem); font-weight: 800; line-height: 1.1; color: #fff; margin-bottom: 1.5rem; letter-spacing: -0.03em; }
.hero__title-line { display: block; }
.hero__title-typed { display: flex; align-items: center; justify-content: center; gap: 0; }
.typed-text { color: var(--color-primary-light); min-width: 1ch; }
.typed-cursor { color: var(--color-primary); animation: blink 1s infinite; font-weight: 300; }
@keyframes blink { 0%,50% { opacity: 1; } 51%,100% { opacity: 0; } }

.hero__subtitle { font-size: 1.15rem; color: var(--color-text-light); line-height: 1.7; margin-bottom: 2.5rem; max-width: 550px; margin-left: auto; margin-right: auto; }
.hero__actions { display: flex; align-items: center; justify-content: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 4rem; }

.hero__stats { display: flex; align-items: center; justify-content: center; gap: 2.5rem; padding-top: 2.5rem; border-top: 1px solid rgba(255,255,255,0.08); }
.hero__stat { text-align: center; }
.hero__stat-number { font-size: 2.25rem; font-weight: 800; color: #fff; }
.hero__stat-suffix { font-size: 2.25rem; font-weight: 800; color: var(--color-primary-light); }
.hero__stat-label { display: block; font-size: 0.8rem; color: var(--color-text-light); margin-top: 0.25rem; text-transform: uppercase; letter-spacing: 0.05em; }
.hero__stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.1); }

/* Scroll indicator */
.hero__scroll-indicator {
  position: absolute; bottom: 2rem; left: 0; right: 0;
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  color: var(--color-text-light); font-size: 0.75rem; opacity: 0.6;
  animation: fadeInUp 1s 1.5s both;
  bottom: -2px;
}
.hero__scroll-mouse { width: 22px; height: 34px; border: 2px solid rgba(255,255,255,0.3); border-radius: 12px; position: relative; }
.hero__scroll-wheel { width: 3px; height: 8px; background: rgba(255,255,255,0.5); border-radius: 2px; position: absolute; top: 6px; left: 50%; transform: translateX(-50%); animation: scrollWheel 2s infinite; }
@keyframes scrollWheel { 0% { transform: translateX(-50%) translateY(0); opacity: 1; } 100% { transform: translateX(-50%) translateY(10px); opacity: 0; } }

/* ============================================
   MARQUEE
   ============================================ */
.marquee {
  padding: 2rem 0; background: var(--color-dark);
  border-top: 1px solid rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  overflow: hidden;
}
.marquee__track { overflow: hidden; }
.marquee__content {
  display: flex; gap: 3rem; align-items: center;
  animation: marqueeScroll 30s linear infinite;
  width: max-content;
}
.marquee__item {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.9rem; font-weight: 500; color: rgba(255,255,255,0.4);
  white-space: nowrap; transition: color 0.3s;
}
.marquee__item svg { opacity: 0.4; }
.marquee__item:hover { color: rgba(255,255,255,0.8); }
@keyframes marqueeScroll { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* ============================================
   SERVICES — Bento Grid
   ============================================ */
.services { padding: 7rem 0; background: var(--color-light); }
.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: auto auto;
  gap: 1.25rem;
}
.bento-card {
  position: relative; background: var(--color-white);
  border-radius: var(--radius-2xl); border: 1px solid var(--color-border);
  overflow: hidden; transition: all var(--transition-slow);
}
.bento-card:hover { border-color: rgba(99,102,241,0.2); box-shadow: var(--shadow-glow); }
.bento-card__glow {
  position: absolute; inset: 0; opacity: 0; transition: opacity 0.5s;
  background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(99,102,241,0.06) 0%, transparent 60%);
}
.bento-card:hover .bento-card__glow { opacity: 1; }
.bento-card__content { padding: 2rem; position: relative; z-index: 1; }
.bento-card__icon {
  width: 56px; height: 56px; border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  background: rgba(139,92,246,0.1); color: var(--color-secondary); margin-bottom: 1.25rem;
}
.bento-card__icon--blue { background: rgba(99,102,241,0.1); color: var(--color-primary); }
.bento-card__icon--cyan { background: rgba(6,182,212,0.1); color: var(--color-accent); }
.bento-card__icon--green { background: rgba(149,191,71,0.1); color: #95bf47; }
.bento-card__title { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.75rem; }
.bento-card__desc { font-size: 0.9rem; color: var(--color-text-muted); line-height: 1.7; margin-bottom: 1.25rem; }
.bento-card__tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.bento-card__tags span {
  padding: 0.25rem 0.75rem; background: var(--color-light);
  border-radius: var(--radius-full); font-size: 0.75rem;
  font-weight: 500; color: var(--color-text-muted);
}

/* Inline metric inside a service card */
.bento-card__inline-metric {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--color-border);
}
.bento-card__inline-metric-number {
  font-size: 2.2rem;
  font-weight: 900;
  line-height: 1;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.bento-card__inline-metric-x {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--color-text);
}
.bento-card__inline-metric-label {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-left: 0.25rem;
}

/* Bento sizes */
.bento-card--large { grid-column: span 2; grid-row: span 2; display: grid; grid-template-columns: 1fr 1fr; }
.bento-card--large .bento-card__content { display: flex; flex-direction: column; justify-content: center; }
.bento-card--medium { grid-column: span 2; }
.bento-card--small { grid-column: span 1; }
.bento-card--metric { grid-column: span 1; display: flex; align-items: center; justify-content: center; }
.bento-card--metric .bento-card__content { text-align: center; }
.bento-card__metric { font-size: 4rem; font-weight: 900; color: var(--color-text); line-height: 1; margin-bottom: 0.5rem; }
.bento-card__metric-number { background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.bento-card__metric-label { font-size: 0.85rem; color: var(--color-text-muted); }

/* Animated border for metric card */
.bento-card__animated-border {
  position: absolute; inset: -1px; border-radius: inherit;
  background: conic-gradient(from var(--angle, 0deg), transparent 60%, var(--color-primary), var(--color-secondary), var(--color-accent), transparent 95%);
  animation: rotateBorder 4s linear infinite;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude; -webkit-mask-composite: xor;
  padding: 2px;
}
@keyframes rotateBorder { to { --angle: 360deg; } }
@property --angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }

/* Mock dashboard inside large card */
.bento-card__visual { padding: 1.5rem; display: flex; align-items: center; }
.mock-dashboard {
  width: 100%; background: var(--color-dark); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  border: 1px solid rgba(255,255,255,0.08);
}
.mock-dashboard__header {
  display: flex; gap: 6px; padding: 0.75rem 1rem;
  background: rgba(255,255,255,0.03); border-bottom: 1px solid rgba(255,255,255,0.05);
}
.mock-dot { width: 10px; height: 10px; border-radius: 50%; }
.mock-dot--red { background: #ef4444; }
.mock-dot--yellow { background: #f59e0b; }
.mock-dot--green { background: #22c55e; }
.mock-dashboard__body { display: flex; min-height: 180px; }
.mock-sidebar { width: 50px; padding: 0.75rem 0.5rem; border-right: 1px solid rgba(255,255,255,0.05); display: flex; flex-direction: column; gap: 0.5rem; }
.mock-nav-item { height: 8px; border-radius: 4px; background: rgba(255,255,255,0.08); }
.mock-nav-item--active { background: var(--color-primary); }
.mock-content { flex: 1; padding: 1rem; display: flex; flex-direction: column; gap: 0.75rem; }
.mock-chart { display: flex; align-items: flex-end; gap: 6px; flex: 1; padding-top: 0.5rem; }
.mock-bar {
  flex: 1; background: var(--gradient-cta); border-radius: 3px 3px 0 0;
  height: var(--h); opacity: 0; animation: growBar 0.6s var(--delay) forwards ease-out;
}
@keyframes growBar { from { height: 0; opacity: 0; } to { height: var(--h); opacity: 1; } }
.mock-stats-row { display: flex; gap: 0.5rem; }
.mock-stat-box { flex: 1; height: 20px; background: rgba(255,255,255,0.05); border-radius: 4px; border: 1px solid rgba(255,255,255,0.08); }

/* ============================================
   PROCESS
   ============================================ */
.process { padding: 7rem 0; background: var(--color-white); }
.process__timeline { position: relative; max-width: 700px; margin: 0 auto; padding-left: 4rem; }
.process__line { position: absolute; left: calc(4rem - 2.5rem + 19px); top: 0; bottom: 0; width: 2px; background: var(--color-border); }
.process__line-fill { width: 100%; height: 0; background: var(--gradient-primary); transition: height 0.8s ease; }
.process__step { position: relative; margin-bottom: 3rem; padding-left: 2rem; }
.process__step:last-child { margin-bottom: 0; }
.process__step-marker {
  position: absolute; left: -2.5rem; top: 0;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--color-white); border: 2px solid var(--color-border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700; color: var(--color-text-muted);
  transition: all 0.4s;
}
.process__step.animate-on-scroll--visible .process__step-marker {
  border-color: var(--color-primary); color: var(--color-primary); box-shadow: 0 0 0 4px rgba(99,102,241,0.1);
}
.process__step-content h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 0.5rem; }
.process__step-content p { font-size: 0.9rem; color: var(--color-text-muted); line-height: 1.7; }

/* ============================================
   PRODUCTS
   ============================================ */
.products { padding: 7rem 0; background: var(--color-light); }
.products__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.product-card-v2 {
  position: relative; background: var(--color-white);
  border-radius: var(--radius-2xl); border: 1px solid var(--color-border);
  overflow: hidden; transition: all var(--transition-slow);
}
.product-card-v2:hover { transform: translateY(-8px) scale(1.02); box-shadow: 0 25px 60px rgba(0,0,0,0.1); }
.product-card-v2__shine {
  position: absolute; top: -100%; left: -100%; width: 200%; height: 200%;
  background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,0.4) 50%, transparent 60%);
  transition: all 0.7s; pointer-events: none; z-index: 2;
}
.product-card-v2:hover .product-card-v2__shine { top: 100%; left: 100%; }
.product-card-v2__image { position: relative; height: 220px; overflow: hidden; background: var(--color-light); }
.product-card-v2__image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s; }
.product-card-v2:hover .product-card-v2__image img { transform: scale(1.08); }
.product-card-v2__overlay {
  position: absolute; inset: 0; background: rgba(10,14,26,0.7); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.3s;
}
.product-card-v2:hover .product-card-v2__overlay { opacity: 1; }
.product-card-v2__btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.6rem 1.25rem; background: #fff; color: var(--color-text);
  border-radius: var(--radius-full); font-size: 0.8rem; font-weight: 600;
  transition: transform 0.2s;
}
.product-card-v2__btn:hover { transform: scale(1.05); }
.product-card-v2__info { padding: 1.5rem; }
.product-card-v2__tag { font-size: 0.7rem; font-weight: 600; color: var(--color-primary); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.5rem; }
.product-card-v2__title { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.4rem; }
.product-card-v2__desc { font-size: 0.85rem; color: var(--color-text-muted); line-height: 1.6; }

/* ============================================
   PROJECTS — Grid layout
   ============================================ */
.projects { padding: 7rem 0; background: var(--color-white); }
.projects__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.project-card-v2 {
  position: relative; display: block;
  border-radius: var(--radius-xl); overflow: hidden;
  height: 260px;
  transition: transform 0.4s, box-shadow 0.4s;
}
.project-card-v2--wide { grid-column: span 2; }
.project-card-v2:hover { transform: translateY(-6px); box-shadow: 0 20px 50px rgba(0,0,0,0.12); }
.project-card-v2 img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.project-card-v2:hover img { transform: scale(1.05); }
.project-card-v2__info {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 1.25rem; background: linear-gradient(to top, rgba(10,14,26,0.9) 0%, rgba(10,14,26,0.6) 50%, transparent 100%);
}
/* Tag color system */
.tag {
  display: inline-block; font-size: 0.7rem; font-weight: 600; color: #fff; text-transform: uppercase; letter-spacing: 0.05em;
  padding: 0.2rem 0.6rem; border-radius: var(--radius-full);
}
.tag--purple { background: #8b5cf6; }
.tag--blue { background: #6366f1; }
.tag--cyan { background: #06b6d4; }
.tag--green { background: #22c55e; }
.tag--orange { background: #f97316; }
.tag--pink { background: #ec4899; }
.project-card-v2__info h4 { font-size: 1.1rem; font-weight: 700; color: #fff; margin-top: 0.5rem; }

/* ============================================
   TESTIMONIALS
   ============================================ */
.testimonials { padding: 7rem 0; background: var(--color-light); }
.testimonials__wrapper { position: relative; max-width: 700px; margin: 0 auto; min-height: 300px; }
.testimonial-v2 {
  position: absolute; inset: 0; background: var(--color-white);
  border-radius: var(--radius-2xl); padding: 2.5rem; border: 1px solid var(--color-border);
  opacity: 0; transform: translateX(40px) scale(0.95); transition: all 0.5s cubic-bezier(0.4,0,0.2,1); pointer-events: none;
}
.testimonial-v2--active { position: relative; opacity: 1; transform: translateX(0) scale(1); pointer-events: all; }
.testimonial-v2__stars { color: #fbbf24; font-size: 1.1rem; margin-bottom: 1.25rem; letter-spacing: 2px; }
.testimonial-v2 blockquote { font-size: 1.1rem; line-height: 1.8; color: var(--color-text); font-style: italic; margin-bottom: 1.5rem; }
.testimonial-v2__author { display: flex; align-items: center; gap: 1rem; }
.testimonial-v2__author img { width: 48px; height: 48px; border-radius: 50%; }
.testimonial-v2__author strong { display: block; font-weight: 600; }
.testimonial-v2__author span { font-size: 0.8rem; color: var(--color-text-muted); }
.testimonials__nav { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-top: 2rem; }
.testimonials__nav button {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--color-border); display: flex; align-items: center; justify-content: center;
  color: var(--color-text-muted); transition: all 0.2s;
}
.testimonials__nav button:hover { border-color: var(--color-primary); color: var(--color-primary); background: rgba(99,102,241,0.05); }

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section { position: relative; padding: 8rem 0; background: var(--gradient-dark); overflow: hidden; }
.cta-section__particles { position: absolute; inset: 0; }
.cta-section__content { position: relative; text-align: center; max-width: 600px; margin: 0 auto; }
.cta-section__content h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; color: #fff; margin-bottom: 1rem; line-height: 1.2; }
.cta-section__content p { font-size: 1.1rem; color: var(--color-text-light); margin-bottom: 2.5rem; line-height: 1.7; }

/* ============================================
   CONTACT
   ============================================ */
.contact { padding: 7rem 0; background: var(--color-white); }
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.contact__text { font-size: 1rem; color: var(--color-text-muted); line-height: 1.7; margin-bottom: 2rem; }
.contact__details { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 2rem; }
.contact__detail { display: flex; align-items: center; gap: 1rem; }
.contact__detail-icon { width: 44px; height: 44px; border-radius: var(--radius-md); background: rgba(99,102,241,0.08); color: var(--color-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact__detail-label { font-size: 0.8rem; color: var(--color-text-muted); }
.contact__detail-value { font-weight: 600; }
.contact__detail-link { color: var(--color-primary); }
.contact__detail-link:hover { text-decoration: underline; }
.contact__trust { display: flex; flex-wrap: wrap; gap: 1rem; }
.contact__trust-item { display: flex; align-items: center; gap: 0.4rem; font-size: 0.8rem; color: var(--color-text-muted); font-weight: 500; }
.contact__trust-item svg { color: var(--color-primary); }
.contact__form-wrapper { background: var(--color-light); border-radius: var(--radius-2xl); padding: 2.5rem; border: 1px solid var(--color-border); }
.form-group { margin-bottom: 1.25rem; }
.form-label { display: block; font-size: 0.85rem; font-weight: 500; margin-bottom: 0.4rem; }
.form-input { width: 100%; padding: 0.875rem 1rem; background: var(--color-white); border: 1px solid var(--color-border); border-radius: var(--radius-md); font-size: 1rem; color: var(--color-text); transition: all 0.2s; outline: none; }
.form-input:focus { border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(99,102,241,0.1); }
.form-input::placeholder { color: var(--color-text-light); }
.form-textarea { min-height: 130px; resize: vertical; }

/* ============================================
   FOOTER
   ============================================ */
.footer { background: var(--color-dark); padding: 4rem 0 1.5rem; }
.footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; padding-bottom: 2rem; border-bottom: 1px solid rgba(255,255,255,0.06); }
.footer__logo { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; }
.footer__desc { font-size: 0.85rem; color: var(--color-text-light); line-height: 1.7; max-width: 280px; }
.footer__heading { font-size: 0.8rem; font-weight: 600; color: #fff; margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 0.05em; }
.footer__list li { margin-bottom: 0.5rem; }
.footer__list a { font-size: 0.85rem; color: var(--color-text-light); transition: color 0.2s; }
.footer__list a:hover { color: #fff; }
.footer__bottom { padding-top: 1.5rem; display: flex; justify-content: space-between; align-items: center; }
.footer__copyright { font-size: 0.8rem; color: var(--color-text-light); }
.footer__built { font-size: 0.8rem; color: rgba(255,255,255,0.3); }

/* ============================================
   BACK TO TOP
   ============================================ */
.back-to-top { position: fixed; bottom: 1.5rem; right: 1.5rem; width: 44px; height: 44px; border-radius: 50%; background: var(--color-primary); color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 15px rgba(99,102,241,0.3); opacity: 0; visibility: hidden; transform: translateY(20px); transition: all 0.3s; z-index: 800; }
.back-to-top--visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { transform: translateY(-3px); box-shadow: 0 8px 25px rgba(99,102,241,0.4); }

/* ============================================
   DECORATIVE DOODLES
   ============================================ */
.deco {
  position: absolute;
  pointer-events: none;
  opacity: 0.07;
  z-index: 0;
}
.deco--sm { width: 80px; height: 80px; }
.deco--md { width: 140px; height: 140px; }
.deco--lg { width: 200px; height: 200px; }
.deco--spin { animation: decoSpin 30s linear infinite; }
.deco--float { animation: decoFloat 8s ease-in-out infinite; }
.deco--drift { animation: decoDrift 12s ease-in-out infinite; }
@keyframes decoSpin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes decoFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-20px); } }
@keyframes decoDrift { 0%, 100% { transform: translate(0,0) rotate(0deg); } 33% { transform: translate(10px,-10px) rotate(5deg); } 66% { transform: translate(-5px,8px) rotate(-3deg); } }

/* ============================================
   ANIMATIONS
   ============================================ */
.animate-on-scroll { opacity: 0; transform: translateY(40px); transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1), transform 0.7s cubic-bezier(0.4,0,0.2,1); }
.animate-on-scroll--visible { opacity: 1; transform: translateY(0); }
.reveal-up { opacity: 0; transform: translateY(30px); animation: fadeInUp 0.8s calc(var(--delay, 0s) + 0.3s) forwards; }
@keyframes fadeInUp { to { opacity: 1; transform: translateY(0); } }

/* Stagger children */
.bento-grid .animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.bento-grid .animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.bento-grid .animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }
.products__grid .animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.products__grid .animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .bento-card--large { grid-template-columns: 1fr; }
  .bento-card__visual { display: none; }
  .products__grid { grid-template-columns: repeat(2, 1fr); }
  .projects__grid { grid-template-columns: repeat(2, 1fr); }
  .projects__grid .project-card-v2--wide { grid-column: span 1; }
  .contact__grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .floating-code { display: none; }
}
@media (max-width: 768px) {
  .nav__toggle { display: flex; }
  .nav__menu { position: fixed; top: 0; right: -100%; width: 80%; max-width: 320px; height: 100vh; background: var(--color-dark); flex-direction: column; align-items: flex-start; padding: 5rem 1.5rem 1.5rem; transition: right 0.4s; box-shadow: -10px 0 40px rgba(0,0,0,0.4); }
  .nav__menu--open { right: 0; }
  .nav__list { flex-direction: column; align-items: flex-start; gap: 1.5rem; width: 100%; }
  .nav__link { font-size: 1.1rem; }
  .nav__dropdown { position: static; transform: none; opacity: 1; visibility: visible; pointer-events: auto; background: rgba(255,255,255,0.03); border: none; box-shadow: none; margin-top: 0.5rem; padding-left: 0.75rem; min-width: auto; }
  .nav__item--dropdown:hover .nav__dropdown { transform: none; }
  .nav__cta { margin-top: 1.5rem; }
  .btn { padding: 0.6rem 1.2rem; font-size: 0.8rem; border-radius: 999px; }
  .btn--lg { padding: 0.75rem 1.5rem; font-size: 0.875rem; }
  .btn--xl { padding: 0.875rem 1.75rem; font-size: 0.95rem; }
  .hero { min-height: auto; padding: 7rem 0 4rem; }
  .hero__badge { font-size: 12px; }
  .hero__title { font-size: 2.2rem; }
  .hero__stats { flex-direction: column; align-items: center; gap: 1.25rem; }
  .hero__stat-divider { width: 40px; height: 1px; }
  .hero__scroll-indicator { display: none; }
  .bento-grid { grid-template-columns: 1fr; }
  .bento-card { border-radius: var(--radius-lg); }
  .bento-card--large, .bento-card--medium { grid-column: span 1; }
  .product-card-v2 { border-radius: var(--radius-lg); }
  .project-card-v2 { border-radius: var(--radius-lg); }
  .products__grid { grid-template-columns: 1fr; }
  .projects__grid { grid-template-columns: 1fr; }
  .projects__grid .project-card-v2--wide { grid-column: span 1; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; gap: 0.5rem; text-align: center; }
  .cta-section { padding: 5rem 0; }
  .hero__shapes { display: none; }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .animate-on-scroll, .reveal-up { opacity: 1; transform: none; }
  .hero__shape, .floating-code { animation: none; }
  .marquee__content { animation: none; }
}
:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; }
