:root {
  --bg-color: #03040A; 
  --surface-color: #09090E;
  --surface-hover: #111116;
  --surface-border: rgba(255, 255, 255, 0.08);
  --text-primary: #FFFFFF;
  --text-secondary: #A1A1AA; 
  --text-muted: #52525B; 
  --accent-color: #3b82f6;
  --accent-gradient: linear-gradient(135deg, #2563eb, #8b5cf6);
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

.background-base {
  position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
  z-index: -10; pointer-events: none; background-color: var(--bg-color);
  background-image: radial-gradient(circle at center top, rgba(37,99,235,0.06), transparent 50%);
}

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 2rem; }
.container-sm { max-width: 800px; }
.mx-auto { margin-left: auto; margin-right: auto; }
.text-center { text-align: center; }

/* NAVBAR */
.navbar {
  position: fixed; top: 1.5rem; left: 50%; transform: translateX(-50%);
  width: 90%; max-width: 1280px; z-index: 100;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 100px; box-shadow: 0 20px 40px -10px rgba(0,0,0,0.5);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease, background 0.3s ease;
}
.navbar.navbar-hidden {
  transform: translate(-50%, -120%) !important; opacity: 0; pointer-events: none;
}
.navbar.navbar-scrolled {
  background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.12); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}
.nav-container { display: flex; align-items: center; justify-content: space-between; height: 60px; padding: 0 1.5rem; }
.logo { font-family: var(--font-heading); font-size: 1.25rem; font-weight: 700; letter-spacing: 0.05em; color: #fff; text-decoration: none; }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { color: var(--text-secondary); text-decoration: none; font-size: 0.875rem; font-weight: 500; transition: color 0.2s; }
.nav-links a:hover, .nav-links a.active { color: var(--text-primary); }

/* UTIL SECTIONS */
.section { padding: 140px 0; }
.bg-subtle { background-color: rgba(255, 255, 255, 0.015); border-top: 1px solid var(--surface-border); border-bottom: 1px solid var(--surface-border); }
.section-header { margin-bottom: 4rem; max-width: 600px; }
.section-title { font-family: var(--font-heading); font-size: 2.5rem; font-weight: 700; margin-bottom: 1rem; letter-spacing: -0.02em; line-height: 1.2; }
.section-subtitle { font-size: 1.125rem; color: var(--text-secondary); max-width: 700px; }

/* LABEL */
.label-small { display: inline-flex; align-items: center; padding: 0.4rem 0.875rem; border-radius: 100px; background: var(--glass-bg); border: 1px solid var(--glass-border); font-size: 0.875rem; font-weight: 500; margin-bottom: 1.5rem; color: #E4E4E7; }
.label-tiny { font-family: var(--font-heading); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-color); margin-bottom: 1rem; }

/* BUTTONS */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.875rem 1.75rem; border-radius: 100px; font-weight: 500; font-size: 0.95rem; transition: all 0.3s; cursor: pointer; text-decoration: none; font-family: var(--font-body);
}
.btn-primary { background: var(--accent-gradient); color: #fff; border: none; box-shadow: 0 8px 24px -4px rgba(37, 99, 235, 0.3); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 32px -4px rgba(37, 99, 235, 0.5); filter: brightness(1.1); color: #fff; }
.btn-secondary { background: transparent; color: var(--text-primary); border: 1px solid var(--glass-border); }
.btn-secondary:hover { border-color: rgba(255, 255, 255, 0.2); background: var(--glass-bg); }
.btn-large { padding: 1.125rem 2.5rem; font-size: 1.125rem; }

/* HERO - Structural Fix for Nested Grids */
.hero-section { 
    padding-top: clamp(120px, 15vh, 180px) !important; /* Forces more space at the top */
    padding-bottom: clamp(60px, 8vh, 100px) !important; 
    display: block !important; 
    width: 100% !important;
    position: relative;
}

.hero-split { 
    display: grid !important; 
    grid-template-columns: 1.1fr 0.9fr !important; 
    gap: 4rem; 
    align-items: center; 
    width: 100% !important;
}

.hero-headline { font-family: var(--font-heading); font-size: clamp(3rem, 5vw, 4.5rem); font-weight: 700; line-height: 1.05; letter-spacing: -0.03em; margin-bottom: 1.5rem; background: linear-gradient(180deg, #FFFFFF 0%, #A1A1AA 100%); background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; animation: fadeUp 0.8s ease-out forwards; }
.hero-subheadline { font-size: 1.25rem; color: var(--text-secondary); margin-bottom: 2.5rem; line-height: 1.6; max-width: 90%; animation: fadeUp 0.8s ease-out forwards; animation-delay: 0.1s; opacity: 0; }
.cta-group { display: flex; gap: 1rem; align-items: center; animation: fadeUp 0.8s ease-out forwards; animation-delay: 0.2s; opacity: 0; }
@keyframes fadeUp { 0% { opacity: 0; transform: translateY(20px); } 100% { opacity: 1; transform: translateY(0); } }

.mockup-frame { 
    border-radius: 30px !important; /* Softer, rounder corners like the design */
    overflow: hidden !important; 
    border: none !important; 
    background: transparent !important; 
    position: relative !important; 
    box-shadow: 0 50px 100px -20px rgba(0, 0, 0, 0.8) !important;
    transform: scale(1.15); /* Significantly larger to match design */
    transform-origin: center right;
}
.mockup-frame img { 
    width: 100% !important; 
    display: block !important; 
    aspect-ratio: 4 / 3 !important; 
    object-fit: cover !important;
    animation: socoFloat 6s ease-in-out infinite !important;
}

@keyframes socoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.hero-visual { 
    animation: fadeUp 0.8s ease-out forwards !important; 
    animation-delay: 0.3s; 
    opacity: 0;
}

/* SERVICES GRID */
.grid { display: grid; gap: 2rem; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.service-card { padding: 2.5rem 2rem; border-radius: 16px; border: 1px solid var(--surface-border); transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); background-color: var(--surface-color); display: flex; flex-direction: column; justify-content: center; min-height: 220px; }
.service-card:hover { border-color: rgba(255, 255, 255, 0.2); transform: translateY(-4px); box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5); background-color: var(--surface-hover); }
.card-title { font-family: var(--font-heading); font-size: 1.5rem; margin-bottom: 1rem; font-weight: 600; color: var(--text-primary); letter-spacing: -0.01em; }
.card-desc { color: var(--text-secondary); font-size: 1rem; line-height: 1.6; }

/* DEEP DIVES */
.deep-dives-container { display: flex; flex-direction: column; gap: 8rem; }
.deep-dive-row { display: grid; grid-template-columns: 1fr 1fr; gap: 6rem; align-items: center; }
.deep-dive-row.reverse .dd-content { order: 2; }
.deep-dive-row.reverse .dd-visual { order: 1; }
.dd-title { font-family: var(--font-heading); font-size: 2.5rem; font-weight: 700; margin-bottom: 1.5rem; color: #fff; line-height: 1.2; letter-spacing: -0.02em; }
.dd-desc { font-size: 1.125rem; color: var(--text-secondary); line-height: 1.7; margin-bottom: 2rem; }
.dd-keywords { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.dd-keywords span { 
    font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; 
    color: var(--text-secondary); background: rgba(255, 255, 255, 0.04); 
    padding: 0.5rem 1rem; border-radius: 100px; border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}
.dd-keywords span:hover { background: rgba(59, 130, 246, 0.1); border-color: rgba(59, 130, 246, 0.3); color: #fff; }
.mockup-link { display: block; text-decoration: none; cursor: pointer; transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
.mockup-link:hover { transform: scale(1.02); }
.dd-visual .mockup-frame { border-radius: 20px; }

/* HOW WE BUILD (TIMELINE) */
.process-timeline { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 4rem; }
.timeline-line { position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--surface-border), transparent); z-index: 0; pointer-events: none; }
.timeline-step { position: relative; z-index: 1; display: flex; align-items: stretch; justify-content: center; }
.step-card { width: 100%; background: var(--surface-color); border: 1px solid var(--surface-border); border-radius: 16px; padding: 2.5rem; position: relative; overflow: hidden; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5); display: flex; flex-direction: column; justify-content: center; }
.step-card:hover { border-color: rgba(255, 255, 255, 0.2); transform: translateY(-4px); background: var(--surface-hover); }
.step-bg-num { position: absolute; top: -0.5rem; right: -0.5rem; font-family: var(--font-heading); font-size: 8rem; font-weight: 700; color: rgba(255, 255, 255, 0.02); pointer-events: none; line-height: 1; letter-spacing: -0.05em; margin: 0; }
.step-title { font-family: var(--font-heading); font-size: 1.5rem; font-weight: 600; color: var(--text-primary); margin-bottom: 0.75rem; position: relative; z-index: 2; }
.step-card p { color: var(--text-secondary); font-size: 1rem; position: relative; z-index: 2; line-height: 1.6; margin: 0; }

/* CTA SECTION */
.cta-section { padding: 120px 0; position: relative; }

/* FOOTER */
.site-footer { border-top: 1px solid var(--surface-border); padding: 5rem 0 2rem; background-color: rgba(255, 255, 255, 0.01); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 4rem; margin-bottom: 4rem; }
.brand-col .logo { font-size: 1.5rem; font-weight: 700; color: #fff; text-decoration: none; font-family: var(--font-heading); letter-spacing: 0.05em; display: block; }
.footer-desc { color: var(--text-muted); margin-top: 1rem; font-size: 0.95rem; line-height: 1.6; }
.footer-heading { font-family: var(--font-heading); font-size: 1rem; font-weight: 600; color: var(--text-primary); margin-bottom: 1.5rem; letter-spacing: 0.05em; text-transform: uppercase; }
.footer-col a { display: block; color: var(--text-secondary); text-decoration: none; font-size: 0.95rem; margin-bottom: 0.75rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--text-primary); }
.footer-bottom { border-top: 1px solid var(--surface-border); padding-top: 2rem; color: var(--text-muted); font-size: 0.875rem; display: flex; justify-content: space-between; align-items: center; }
.footer-legal { display: flex; gap: 2rem; }
.footer-legal a { color: var(--text-muted); text-decoration: none; transition: color 0.2s; }
.footer-legal a:hover { color: var(--text-secondary); }

/* RESPONSIVE */
@media (max-width: 1024px) {
  .hero-split { grid-template-columns: 1fr; text-align: center; gap: 4rem; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .process-timeline { grid-template-columns: 1fr; gap: 2rem; }
  .timeline-line { display: none; }
  .deep-dive-row { grid-template-columns: 1fr; gap: 4rem; text-align: center; }
  .deep-dive-row.reverse .dd-content { order: 1; }
  .deep-dive-row.reverse .dd-visual { order: 2; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .cta-group { justify-content: center; }
  .hero-subheadline { margin-left: auto; margin-right: auto; }
}

@media (max-width: 640px) {
  .grid-4 { grid-template-columns: 1fr; }
  .hero-headline { font-size: 2.5rem; }
  .cta-group { flex-direction: column; width: 100%; }
  .btn { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 3rem; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .section { padding: 60px 0; }
  .deep-dives-container { gap: 5rem; }
}
