:root {
  --background: #000000;
  --surface: #0d0d18;
  --card-dark: #0a0a14;
  --primary: #3e3f7e;
  --secondary: #a2a3e9;
  --accent: #696aac;
  --foreground: #f6f6fd;
  --muted: #9494a8;
  --muted-foreground: #6b7280;
  --light-accent: #e3e3f8;
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-serif: "Instrument Serif", serif;
}

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

body {
  background-color: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 1.125rem;
  line-height: 1.6;
  overflow-x: hidden;
}

.section-tag {
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: 2rem;
  display: block;
}

.section-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: white;
}

/* Utilities */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (min-width: 768px) {
  .container {
    padding: 0 3rem;
  }
}

.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

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

.justify-center {
  justify-content: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-2 {
  gap: 0.5rem;
}

.gap-3 {
  gap: 0.75rem;
}

.gap-4 {
  gap: 1rem;
}

.gap-8 {
  gap: 2rem;
}

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

.uppercase {
  text-transform: uppercase;
}

.italic {
  font-style: italic;
}

.font-light {
  font-weight: 300;
}

.font-normal {
  font-weight: 400;
}

.font-medium {
  font-weight: 500;
}

.font-bold {
  font-weight: 700;
}

/* Navbar Base */
nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 1.5rem 0;
  transition: all 0.3s ease;
}

nav.scrolled {
  background: rgba(2, 2, 2, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 1rem 0;
}

.logo {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: white;
}

.nav-brand, .btn-get-in-touch {
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (min-width: 1024px) {
  nav.scrolled .nav-brand,
  nav.scrolled .btn-get-in-touch {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
  }
}

/* New Premium Desktop Navbar v2 */
.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  position: relative;
}

.nav-brand {
  flex: 1;
  display: flex;
  align-items: center;
}

.nav-pill-wrapper {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
}

.nav-pill {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  padding: 0.4rem;
  display: flex;
  gap: 0.25rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-pill:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.nav-pill a {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
  padding: 0.6rem 1.5rem;
  border-radius: 9999px;
  transition: all 0.3s;
}

.nav-pill a:hover {
  color: white;
  background: rgba(255, 255, 255, 0.08);
}

.nav-actions {
  flex: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.btn-get-in-touch {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.6rem 1.5rem;
  background: white;
  color: black;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-get-in-touch:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.icon-circle {
  background: #000;
  color: #fff;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-get-in-touch:hover .icon-circle {
  transform: rotate(45deg);
  background: var(--primary);
}

/* Hero Section */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 700px; /* Reduced from 800px */
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: #000;
}

@media (max-width: 768px) {
  .hero {
    min-height: 600px;
    padding-top: 80px;
  }
}

.watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 0;
  opacity: 0.05;
  font-size: 20vw;
  font-weight: 700;
  letter-spacing: -0.05em;
  color: white;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  will-change: transform;
}

@keyframes driftLeft {
  0% {
    transform: translate(-49%, -50%);
  }

  100% {
    transform: translate(-51%, -50%);
  }
}

#canvas-container {
  position: absolute;
  inset: 0;
  z-index: 10;
  pointer-events: none;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
}

.hero-content {
  position: relative;
  z-index: 20;
  width: 100%;
  animation: float 6s ease-in-out infinite;
  will-change: transform;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

.hero-title {
  font-size: clamp(36px, 10vw, 96px); /* Adjusted starting size */
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 2rem;
}

.serif-italic {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.6);
  max-width: 520px;
  margin-bottom: 3rem;
  font-weight: 300;
}

@media (max-width: 768px) {
  .hero-subtitle {
    font-size: 1rem;
  }
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  padding: 1.125rem 2.5rem;
  border-radius: 100px;
  background: linear-gradient(93.92deg, #8587e3 -13.51%, #4c4dac 40.91%, #696aac 113.69%);
  color: white;
  text-decoration: none;
  font-weight: 500;
  box-shadow: 0 0 10px #696aac, inset 0 0 2px rgba(255, 255, 255, 0.6);
  transition: all 0.3s;
}

.btn-primary:hover {
  transform: scale(1.05);
}

.btn-primary .icon-bg {
  background: white;
  color: black;
  border-radius: 50%;
  padding: 0.375rem;
  display: flex;
  transition: all 0.3s;
}

.btn-primary:hover .icon-bg {
  transform: translate(3px, -3px);
}

.stats-bar {
  position: absolute;
  bottom: 4rem;
  right: 3rem;
  z-index: 20;
  display: none;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .stats-bar {
    display: flex;
  }
}

.stat-item {
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  padding-left: 1.5rem;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 0.25rem;
  display: flex;
  align-items: center;
}

.stat-value sup {
  font-size: 1.25rem;
  margin-top: -0.5rem;
}

.stat-label {
  font-size: 0.9375rem;
  /* Increased from 13px to 15px */
  color: var(--muted);
  max-width: 100px;
  line-height: 1.2;
}

/* Services Bento Section (V4) */
.services-bento-section {
  padding: 120px 0; /* Reduced from 180px */
  background: #000;
  position: relative;
  overflow: hidden;
  z-index: 10;
}

@media (max-width: 768px) {
  .services-bento-section {
    padding: 80px 0;
  }
}

.services-header-v4 {
  text-align: center;
  margin-bottom: 4rem; /* Reduced from 6rem */
  position: relative;
  z-index: 20;
}

@media (max-width: 768px) {
  .services-header-v4 {
    margin-bottom: 3rem;
  }
}

.bento-grid-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 480px;
  gap: 2rem;
  position: relative;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.bento-tile {
  position: relative;
  border-radius: 2.5rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(24px);
  padding: 3rem;
  overflow: hidden;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 320px;
}

/* Glass Grain Overlay */
.bento-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("https://grainy-gradients.vercel.app/noise.svg");
  opacity: 0.03;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 1;
}

.bento-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.05), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.bento-tile:hover::before {
  transform: translateX(100%);
}

.tile-glass {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(162, 163, 233, 0.08), transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
  z-index: 1;
}

.bento-tile:hover {
  transform: translateY(-8px);
  border-color: rgba(255, 255, 255, 0.15);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.bento-tile:hover .tile-glass {
  opacity: 1;
}

/* Grid Layout Assignments */
.tile-large {
  grid-column: span 2;
  grid-row: span 2;
  justify-content: center;
}

.tile-medium {
  grid-column: span 2;
  grid-row: span 1;
  justify-content: flex-end; /* Align to bottom like large tiles */
}

.tile-small {
  grid-column: span 1;
  grid-row: span 1;
}

/* Tile Components */
.tile-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: auto;
}

.tile-num {
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
  opacity: 0.5;
}

.tile-icon {
  width: 4rem;
  height: 4rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  z-index: 2;
}

.bento-tile:hover .tile-icon {
  background: var(--secondary);
  color: white;
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 0 20px rgba(162, 163, 233, 0.3);
}

.tile-title {
  font-size: 2.25rem;
  font-weight: 500;
  color: white;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.tile-desc {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.125rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  max-width: 100%;
  font-weight: 300;
}

.tile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.tile-tags span {
  background: rgba(162, 163, 233, 0.25);
  color: #fff;
  padding: 0.5rem 1.25rem;
  border-radius: 100px;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid rgba(162, 163, 233, 0.4);
  font-weight: 500;
}

.tile-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: white;
  text-decoration: none;
  font-weight: 600;
  transition: gap 0.3s ease;
}

.bento-tile:hover .tile-link {
  color: var(--secondary);
  gap: 1.25rem;
}

/* Morphic Visual Anchor */
.bento-visual-anchor {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  z-index: 1;
  pointer-events: none;
  opacity: 0.4;
  filter: blur(80px);
  /* Diffused background glow */
}

#services-3d-visual {
  width: 100%;
  height: 100%;
}

@media (max-width: 1200px) {
  .bento-grid-container {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(4, 240px);
    gap: 1.25rem;
  }

  .tile-large {
    grid-column: span 3;
    grid-row: span 2;
  }

  .tile-medium {
    grid-column: span 3;
    grid-row: span 1;
  }

  .tile-small {
    grid-column: span 1;
    grid-row: span 1;
  }
}

@media (max-width: 900px) {
  .bento-grid-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .tile-large,
  .tile-medium,
  .tile-small {
    grid-column: span 1;
    grid-row: auto;
    min-height: 380px;
  }
}

/* Staggered Entrance */
.bento-tile.reveal:nth-child(1) {
  transition-delay: 0.1s;
}

.bento-tile.reveal:nth-child(2) {
  transition-delay: 0.2s;
}

.bento-tile.reveal:nth-child(3) {
  transition-delay: 0.3s;
}

.bento-tile.reveal:nth-child(4) {
  transition-delay: 0.4s;
}

.bento-tile.reveal:nth-child(5) {
  transition-delay: 0.5s;
}

.bento-tile.reveal:nth-child(6) {
  transition-delay: 0.6s;
}

@media (max-width: 768px) {
  .tile-title {
    font-size: 1.75rem;
  }

  .tile-desc {
    font-size: 1rem;
  }
}

/* Products */
.products {
  background-color: #050510;
  padding: 120px 0; /* Reduced from 160px */
  position: relative;
  z-index: 5;
}

@media (max-width: 768px) {
  .products {
    padding: 80px 0;
  }
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

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

.product-card {
  position: relative;
  overflow: hidden;
  padding: 3.5rem;
  border-radius: 2.5rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(24px);
}

/* Glass Grain Overlay */
.product-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("https://grainy-gradients.vercel.app/noise.svg");
  opacity: 0.02;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 1;
}

.product-glow {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: radial-gradient(circle at center, rgba(162, 163, 233, 0.12), transparent 70%);
  transition: opacity 0.8s ease;
  pointer-events: none;
}

.product-card:hover {
  transform: translateY(-12px);
  border-color: rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.product-card:hover .product-glow {
  opacity: 1;
}

.product-content {
  position: relative;
  z-index: 10;
}

.product-icon-box {
  width: 4.5rem;
  height: 4.5rem;
  background: rgba(162, 163, 233, 0.08); /* Consistent with theme secondary opacity */
  border: 1px solid rgba(162, 163, 233, 0.15);
  border-radius: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary);
  margin-bottom: 2.5rem;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.product-card:hover .product-icon-box {
  background: var(--secondary);
  color: white;
  transform: scale(1.1) rotate(5deg);
}

.product-id {
  font-size: 1.125rem;
  /* 18px */
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.1em;
  opacity: 0.5;
}

.product-card .card-title {
  font-size: 2.25rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  color: white;
  letter-spacing: -0.02em;
}

.product-card .card-text {
  font-size: 1.25rem;
  /* 20px */
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 2.5rem;
}

.learn-more {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: white;
  font-weight: 600;
  font-size: 1.125rem;
  /* 18px */
  transition: all 0.3s ease;
}

.learn-more i {
  width: 1.25rem;
  height: 1.25rem;
  transition: transform 0.3s ease;
}

.product-card:hover .learn-more {
  color: var(--secondary);
  gap: 1.25rem;
}

.product-card:hover .learn-more i {
  transform: translateX(4px);
}

/* Case Studies */
.case-studies {
  padding: 120px 0; /* Reduced from 160px */
  background: #000;
}

@media (max-width: 768px) {
  .case-studies {
    padding: 80px 0;
  }
}

.case-study {
  cursor: pointer;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
  position: relative;
  border-radius: 3rem;
  padding: 2.5rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
  border: 1px solid rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(20px);
}

/* Featured lead case study */
.case-study:first-child {
  grid-column: span 2;
}

@media (max-width: 991px) {
  .case-study:first-child {
    grid-column: span 1;
  }
}

.case-study:hover {
  transform: translateY(-12px);
  border-color: rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.study-image {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  border-radius: 2rem;
  margin-bottom: 2rem;
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.study-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.8;
  transition: all 0.7s;
  will-change: transform, opacity;
}

.case-study:hover .study-image img {
  transform: scale(1.1);
  opacity: 1;
}

.study-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
  opacity: 0;
  transition: opacity 0.5s;
}

.case-study:hover .study-overlay {
  opacity: 1;
}

.study-arrow {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  border-radius: 50%;
  opacity: 0;
  transform: translateY(1rem);
  transition: all 0.5s;
}

.case-study:hover .study-arrow {
  opacity: 1;
  transform: translateY(0);
  background: var(--secondary);
  color: white;
}

.case-study .card-title {
  font-size: 1.75rem;
  font-weight: 500;
  color: white;
  margin-top: 1rem;
}

.tag {
  font-size: 0.875rem;
  /* 14px */
  padding: 0.5rem 1.25rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 100px;
  color: rgba(255, 255, 255, 0.6);
}

/* Logos */
.logos-slider {
  display: flex;
  overflow: hidden;
  position: relative;
}

.logos-track {
  display: flex;
  gap: 3rem;
  padding-right: 3rem;
  animation: scrollLogos 30s linear infinite;
}

@keyframes scrollLogos {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

.logo-item {
  font-size: 2rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.1);
  letter-spacing: -0.05em;
  transition: color 0.3s;
}

@media (min-width: 768px) {
  .logos-track {
    gap: 6rem;
    padding-right: 6rem;
  }

  .logo-item {
    font-size: 3rem;
  }
}

.logo-item:hover {
  color: rgba(255, 255, 255, 0.3);
}

/* Mobile Menu Styles */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(2, 2, 2, 0.95);
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(-20px);
}

.mobile-menu-overlay.active {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.5rem;
}

.mobile-menu-links a {
  color: white;
  text-decoration: none;
  font-size: 2.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  transition: all 0.3s;
  opacity: 0;
  transform: translateY(20px);
}

.mobile-menu-overlay.active .mobile-menu-links a {
  opacity: 1;
  transform: translateY(0);
}

.mobile-menu-overlay.active .mobile-menu-links a:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu-overlay.active .mobile-menu-links a:nth-child(2) { transition-delay: 0.2s; }
.mobile-menu-overlay.active .mobile-menu-links a:nth-child(3) { transition-delay: 0.3s; }
.mobile-menu-overlay.active .mobile-menu-links a:nth-child(4) { transition-delay: 0.4s; }
.mobile-menu-overlay.active .mobile-menu-links a:nth-child(5) { transition-delay: 0.5s; }

.close-menu {
  position: absolute;
  top: 2rem;
  right: 2rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s;
}

.close-menu:hover {
  background: white;
  color: black;
  transform: rotate(90deg);
}

.md-only {
    padding: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    transition: background 0.3s;
}

.md-only:active {
    background: rgba(255, 255, 255, 0.1);
}

/* Helper classes */
.hidden { display: none; }
.md-flex { display: none; }
.md-only { display: flex; }
.lg-flex { display: none; }
.lg-only { display: flex; }

@media (min-width: 768px) {
  .md-flex { display: flex; }
  .md-only { display: none; }
}

@media (min-width: 1024px) {
  .lg-flex { display: flex; }
  .lg-only { display: none; }
}

/* CTA */
.cta {
  padding: 120px 0; /* Reduced from 160px */
  position: relative;
  overflow: hidden;
  background: #000;
}

@media (max-width: 768px) {
  .cta {
    padding: 80px 0;
  }
}

.cta-title {
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.04em;
  margin-bottom: 4rem;
  color: white;
}

.cta-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(circle at center, rgba(62, 63, 126, 0.15) 0%, transparent 70%);
  filter: blur(140px);
  pointer-events: none;
  z-index: 1;
}

.btn-white {
  padding: 1.25rem 3.5rem;
  border-radius: 100px;
  background: white;
  color: black;
  font-weight: 600;
  font-size: 1.125rem;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
}

.btn-white:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 255, 255, 0.2);
}

/* Footer Redesign */
/* Premium Footer Overhaul */
footer {
  padding: 80px 0 40px; /* Reduced from 100px 0 60px */
  background: #000;
  position: relative;
  overflow: hidden;
}

.footer-orbital-glow {
  position: absolute;
  top: -30%;
  left: 50%;
  transform: translateX(-50%);
  width: 250%;
  height: 180%;
  background: radial-gradient(ellipse at center, rgba(162, 163, 233, 0.08) 0%, transparent 60%);
  filter: blur(140px);
  pointer-events: none;
  z-index: 1;
}

.footer-massive-logo {
  position: relative;
  z-index: 2;
  text-align: center;
  margin-bottom: 4rem;
  pointer-events: none;
}

.footer-massive-logo h2 {
  font-size: clamp(4rem, 12vw, 16rem);
  font-weight: 700;
  line-height: 0.7;
  letter-spacing: -0.07em;
  color: rgba(255, 255, 255, 0.02);
  text-transform: uppercase;
  user-select: none;
}

.footer-grid-v2 {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 4rem;
  margin-bottom: 4rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

@media (max-width: 1024px) {
  .footer-grid-v2 {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

@media (max-width: 768px) {
  .footer-grid-v2 {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
  }
}

.footer-brand-v2 .logo {
  font-size: 2rem;
  margin-bottom: 2rem;
  display: block;
  background: linear-gradient(90deg, #fff 0%, #a2a3e9 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-brand-v2 p {
  color: var(--muted);
  font-size: 1.125rem;
  line-height: 1.7;
  max-width: 320px;
  margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
  .footer-brand-v2 p {
    max-width: none;
  }
}

.footer-nav-unit-v2 h4 {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: white;
  margin-bottom: 1.25rem;
  font-weight: 600;
}

.footer-nav-unit-v2 ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-nav-unit-v2 a {
  color: var(--muted);
  text-decoration: none;
  font-size: 1.125rem;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
}

.footer-nav-unit-v2 a:hover {
  color: white;
  transform: translateX(5px);
}

@media (max-width: 768px) {
  .footer-nav-unit-v2 a:hover {
    transform: translateY(-3px);
  }
}

.footer-bottom-v2 {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 0;
}

.footer-bottom-v2 .copyright {
  color: rgba(255, 255, 255, 0.2);
  font-size: 0.9375rem;
}

.footer-socials-v2 {
  display: flex;
  gap: 1.5rem;
}

.social-orb-v2 {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}

.social-orb-v2:hover {
  background: white;
  color: black;
  transform: translateY(-5px);
}

@media (max-width: 768px) {
  .footer-bottom-v2 {
    flex-direction: column-reverse;
    gap: 3rem;
    text-align: center;
  }
}

/* Scroll Animations */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* About Section Styles */
.about-section {
  padding: 120px 0;
  background-color: var(--background);
  position: relative;
  z-index: 5;
}

@media (max-width: 768px) {
  .about-section {
    padding: 80px 0;
  }
}

.section-description {
  font-size: 1.25rem;
  color: var(--muted);
  line-height: 1.6;
  font-weight: 300;
}

.gap-24 {
  gap: 6rem;
}

@media (max-width: 1024px) {
  .gap-24 {
    gap: 3rem;
  }
}

.about-visual .product-card:hover {
  transform: none; /* Disable hover lift for static visual */
  border-color: rgba(255, 255, 255, 0.05);
}

/* Personal Profile Photo Frame */
.developer-photo-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 0.85;
  border-radius: 3rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.5);
  background: rgba(255, 255, 255, 0.02);
}

.developer-photo-frame img {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.developer-photo-frame:hover img {
  transform: scale(1.05);
}

.photo-aura {
  position: absolute;
  inset: -20%;
  background: radial-gradient(circle at center, rgba(162, 163, 233, 0.15), transparent 70%);
  animation: aura-rotate 20s linear infinite;
  z-index: 1;
}

@keyframes aura-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.academic-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(162, 163, 233, 0.1);
  border: 1px solid rgba(162, 163, 233, 0.2);
  padding: 0.5rem 1.25rem;
  border-radius: 100px;
  color: var(--secondary);
  font-size: 0.875rem;
  font-weight: 500;
  margin-top: 1.5rem;
}