@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500&family=Outfit:wght@300;600;800&display=swap');

:root {
  --bg-deep: #050505;
  --bg-surface: #0a0a0a;
  --bg-elevated: #111111;
  
  --accent-orange: #333333; /* Fallbacks for the orbs, now grayscale */
  --accent-purple: #1a1a1a;
  --accent-magenta: #222222;
  
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.6);
  --text-muted: rgba(255, 255, 255, 0.4);
  
  --rainbow-gradient: linear-gradient(to right, #833ab4, #fd1d1d, #fcb045, #fd1d1d, #833ab4);
  --card-bg: rgba(15, 15, 15, 0.6);
  --card-border: rgba(255, 255, 255, 0.08);
  
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-6: 48px;
  --space-8: 64px;
  --space-12: 96px;
  --space-16: 128px;
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--bg-deep);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 24px;
}

body {
  overflow-x: hidden;
  position: relative;
}

/* Background Textures */
.bg-texture {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -2;
  pointer-events: none;
  background-size: 50px 50px;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
}

.orbs-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(150px);
  opacity: 0.5;
  animation: float 20s infinite ease-in-out;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(30px, -50px) scale(1.1);
  }
  66% {
    transform: translate(-20px, 20px) scale(0.9);
  }
}

.orb-1 {
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background-color: var(--accent-purple);
  animation-delay: 0s;
}

.orb-2 {
  bottom: -10%;
  right: -10%;
  width: 40vw;
  height: 40vw;
  background-color: var(--accent-magenta);
  animation-delay: -5s;
}

.orb-3 {
  top: 40%;
  left: 50%;
  width: 30vw;
  height: 30vw;
  background-color: var(--accent-orange);
  transform: translate(-50%, -50%);
  opacity: 0.3;
  animation-duration: 25s;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 800;
  letter-spacing: -1px;
}

h1 {
  font-size: 48px;
  line-height: 56px;
  margin-bottom: 8px;
}

h2 {
  font-size: 32px;
  line-height: 40px;
  margin-bottom: 8px;
}

h3 {
  font-size: 24px;
  line-height: 32px;
  margin-bottom: 8px;
}

p {
  font-size: 16px;
  line-height: 24px;
  color: var(--text-secondary);
  margin-top: 0;
  margin-bottom: var(--space-3);
}

.text-rainbow {
  background: var(--rainbow-gradient);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
  animation: shine 6s linear infinite;
}

@keyframes shine {
  to {
    background-position: 200% center;
  }
}

/* Blur Text Animation Styles (React Bits Port) */
.split-text-trigger {
}

.split-word {
  display: inline-block;
  opacity: 0;
  filter: blur(12px);
  transform: translate3d(0, 15px, 0);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
              filter 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

.split-text-trigger.active .split-word {
  opacity: 1;
  filter: blur(0px);
  transform: translate3d(0, 0, 0);
}

.subtitle {
  font-size: 20px;
  line-height: 28px;
  color: var(--text-secondary);
  max-width: 800px;
  margin-top: 0;
  margin-bottom: var(--space-4);
}

.text-center {
  text-align: center;
}

.text-center p,
.text-center .subtitle {
  margin-left: auto;
  margin-right: auto;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-3);
}

.page-header,
.content-section > .text-block {
  text-align: center;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-header p,
.page-header .subtitle,
.content-section > .text-block p,
.content-section > .text-block .subtitle {
  margin-left: auto;
  margin-right: auto;
}

section {
  padding: 160px 0;
}

/* Header */
.header {
  position: fixed;
  top: 24px;
  left: 0;
  width: 100%;
  z-index: 100;
  border: none;
  background: transparent !important;
  pointer-events: none;
  display: flex;
  justify-content: center;
  padding: 0 var(--space-3);
}

.header-container {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 72px;
  padding: 0 var(--space-4);
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  border-radius: 50px;
  pointer-events: auto;
  border: 1px solid var(--card-border);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
}

.logo {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 24px;
  line-height: 32px;
  color: var(--text-primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.logo-img {
  height: 32px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: var(--space-4);
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--text-primary);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  border-radius: 4px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 16px;
  line-height: 24px;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
}

.btn:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.btn-primary {
  background-color: #ffffff;
  color: #000000;
}

.btn-primary:hover {
  background-color: #d0d0d0;
  box-shadow: 0 0 24px rgba(255, 255, 255, 0.2);
}

.btn-secondary {
  background-color: transparent;
  color: #ffffff;
  border: 1px solid var(--card-border);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.header .btn {
  padding: 12px 24px;
  font-size: 16px;
  line-height: 24px;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 80px;
}

.hero-content {
  max-width: 900px;
}

.hero-cta {
  display: flex;
  gap: var(--space-2);
  justify-content: center;
  margin-top: var(--space-6);
  margin-bottom: var(--space-6);
}

.social-proof {
  font-size: 0.875rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 500;
  margin-top: 64px;
}

.hero-fade-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 300px;
  background: linear-gradient(to bottom, transparent 0%, var(--bg-deep) 100%);
  z-index: 1;
  pointer-events: none;
}

/* Bento Grid Services */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-3);
}

.card {
  background-color: transparent;
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 48px 32px;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

/* Glass Surface (React Bits Port) */
.glass-surface {
  /* removed position: relative to avoid overriding fixed headers */
}

.glass-surface__filter {
  width: 100%;
  height: 100%;
  pointer-events: none;
  position: absolute;
  inset: 0;
  opacity: 0;
  z-index: -1;
}

.glass-surface--svg {
  background: rgba(10, 10, 12, 0.25) !important;
  backdrop-filter: blur(16px) var(--filter-id, url(#glass-filter));
  -webkit-backdrop-filter: blur(16px) var(--filter-id, url(#glass-filter));
  box-shadow:
    0 0 2px 1px rgba(255, 255, 255, 0.08) inset,
    0 0 10px 4px rgba(255, 255, 255, 0.03) inset,
    0px 8px 32px rgba(0, 0, 0, 0.5);
  border: none !important;
}

.glass-surface--fallback {
  background: rgba(10, 10, 12, 0.4) !important;
  backdrop-filter: blur(16px) saturate(160%) contrast(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(160%) contrast(1.1);
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    600px circle at var(--mouse-x) var(--mouse-y), 
    rgba(255, 255, 255, 0.08),
    transparent 40%
  );
  z-index: 0;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.card:hover::before {
  opacity: 1;
}

/* Add subtle noise texture inside the card for the particle feel */
.card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.03;
  z-index: 0;
  pointer-events: none;
}

.card > * {
  z-index: 1;
  position: relative;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 
    inset 0 1px 1px rgba(255, 255, 255, 0.3), 
    inset 0 -1px 2px rgba(0, 0, 0, 0.3), 
    0 16px 48px rgba(0, 0, 0, 0.5);
}

.card-icon {
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-3);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--card-border);
}

.card-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--text-primary);
}

.service-main {
  grid-column: span 12;
}

@media (min-width: 768px) {
  .service-main { grid-column: span 8; }
  .service-ai { grid-column: span 4; }
  .service-web { grid-column: span 6; }
  .service-mkt { grid-column: span 6; }
}

@media (min-width: 1024px) {
  .service-main { grid-column: span 6; grid-row: span 2; }
  .service-ai { grid-column: span 6; }
  .service-web { grid-column: span 3; }
  .service-mkt { grid-column: span 3; }
}

/* Methodology */
.steps-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  position: relative;
}

@media (min-width: 768px) {
  .steps-container {
    grid-template-columns: repeat(4, 1fr);
  }
}

.step {
  padding: var(--space-4) 0;
  border-top: 1px solid var(--card-border);
}

.step-number {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 800;
  color: var(--text-muted);
  margin-bottom: var(--space-2);
  line-height: 1;
}

/* Success Cases */
.case-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
}

@media (min-width: 768px) {
  .case-card {
    grid-template-columns: 1fr 1fr;
  }
}

.case-image {
  width: 100%;
  aspect-ratio: 16/9;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.metric-value {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: var(--space-1);
}

.metric-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* DNA / About */
.dna-section {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

/* Footer & Bottom CTA */
.bottom-cta {
  background: var(--card-bg);
  border-top: 1px solid var(--card-border);
  border-bottom: 1px solid var(--card-border);
  text-align: center;
  padding: var(--space-12) var(--space-3);
}

.footer {
  margin-top: 120px;
  padding: var(--space-8) var(--space-3) var(--space-4);
  background: var(--bg-deep);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  margin-bottom: var(--space-6);
}

@media (min-width: 768px) {
  .footer-content {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.footer-col h4 {
  color: var(--text-primary);
  margin-bottom: var(--space-3);
  font-size: 20px;
  line-height: 28px;
}

.footer-col p {
  font-size: 14px;
  line-height: 24px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: var(--space-2);
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 20px;
  padding-top: var(--space-4);
  border-top: 1px solid var(--card-border);
  max-width: 1200px;
  margin: 0 auto;
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px) scale(0.98);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }

/* Responsive Adjustments */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .hero-cta {
    flex-direction: column;
  }
  
  .btn {
    width: 100%;
  }
  
  .header-container {
    padding: 0 var(--space-2);
  }
  
  .container {
    padding: 0 var(--space-2);
  }
}

/* Specular Button Effects */
.btn-specular {
  --sb-radius: 4px;
  --sb-tint: #ffffff;
  --sb-tint-opacity: 0;
  --sb-blur: 0px;
  --sb-text-color: #ffffff;

  position: relative;
  border: none;
  background: color-mix(in srgb, var(--sb-tint) calc(var(--sb-tint-opacity) * 100%), transparent) !important;
  border-radius: var(--sb-radius);
  backdrop-filter: blur(var(--sb-blur));
  -webkit-backdrop-filter: blur(var(--sb-blur));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 8px 24px rgba(0, 0, 0, 0.25);
  overflow: visible !important;
  text-decoration: none;
}

.btn-specular:active {
  transform: scale(0.97);
}

.specular-button__fx {
  position: absolute;
  inset: -20px;
  pointer-events: none;
  z-index: 1;
}

.specular-button__fx canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.specular-button__label {
  position: relative;
  z-index: 2;
}
