/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Agentic Orbit Color Palette - Night Mood */
  --black: #000000;
  --white: #ffffff;
  --graphite: #0d0d1a;
  --graphite-light: #0a0a14;
  --graphite-dark: #050510;
  --dark-blue: #0a0a1e;
  --accent-cyan: #18e0e0;
  --electric-blue: #22c3f7;
  --grey-light: #f5f5f5;
  --grey-medium: #8b8ba0;
  --grey-dark: #1a1a1a;

  /* Semantic Colors */
  --primary-color: var(--accent-cyan);
  --secondary-color: var(--electric-blue);
  --bg-primary: var(--black);
  --bg-secondary: var(--graphite);
  --bg-light: var(--white);
  --darker-bg: var(--graphite-dark);
  --dark-bg: var(--graphite-dark);
  --text-primary: var(--white);
  --text-secondary: var(--grey-medium);
  --text-inverse: var(--black);
  --border-color: rgba(255, 255, 255, 0.1);
  --accent-gradient: linear-gradient(
    135deg,
    var(--accent-cyan) 0%,
    var(--electric-blue) 100%
  );

  /* Typography */
  --font-heading: "Space Grotesk", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;

  /* Spacing */
  --section-padding: 120px;
  --container-padding: 80px;

  /* Transitions - purposeful motion */
  --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: #000000;
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color 0.4s cubic-bezier(0.4, 0, 0.2, 1),
    color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Day Mode Styles */
body.day-mode {
  background-color: #fafafa;
  --bg-primary: #fafafa;
  --bg-secondary: #f0f0f0;
  --graphite: #e5e5ea;
  --graphite-light: #f5f5f7;
  --graphite-dark: #d1d1d6;
  --dark-blue: #e8e8f0;
  --text-primary: #1d1d1f;
  --text-secondary: #6e6e73;
  --border-color: rgba(0, 0, 0, 0.08);
}

body.day-mode .hero {
  background: #ffffff !important;
}

body.day-mode .value-proposition {
  background: #ffffff !important;
}

body.day-mode .approach {
  background: #ffffff !important;
}

body.day-mode .why-Ajentica {
  background: #ffffff !important;
}

body.day-mode .results {
  background: #ffffff !important;
}

body.day-mode .engagement-model {
  background: #ffffff !important;
}

body.day-mode .about-us {
  background: #ffffff !important;
}

body.day-mode .cta {
  background: #ffffff !important;
}

body.day-mode .footer {
  background: #ffffff !important;
  border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
}

body.day-mode .navbar {
  background: rgba(255, 255, 255, 0.98) !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

body.day-mode .principle {
  background: rgba(255, 255, 255, 0.8) !important;
  border: 1px solid rgba(24, 224, 224, 0.25) !important;
}

body.day-mode .model-card {
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(24, 224, 224, 0.25) !important;
}

body.day-mode .cta-content {
  background: rgba(255, 255, 255, 0.95) !important;
  border: 1px solid rgba(24, 224, 224, 0.3) !important;
}

body.day-mode .feature-card {
  background: F5F5F7 !important;
}

body.day-mode .orbit {
  border-color: rgba(24, 224, 224, 0.4) !important;
}

body.day-mode .orbit::before {
  background: var(--accent-cyan);
  box-shadow: 0 0 30px var(--accent-cyan), 0 0 15px rgba(24, 224, 224, 0.6);
}

body.day-mode .hero::before {
  background: transparent !important;
}

body.day-mode h1,
body.day-mode h2,
body.day-mode h3,
body.day-mode h4,
body.day-mode h5,
body.day-mode h6 {
  color: #1d1d1f;
}

body.day-mode .hero-title {
  color: #1d1d1f !important;
}

body.day-mode .section-title {
  color: #1d1d1f;
}

body.day-mode .logo a {
  color: #1d1d1f;
}

body.day-mode .nav-menu a {
  color: #6e6e73;
}

body.day-mode .nav-menu a:hover {
  color: #1d1d1f;
}

body.day-mode .approach-step {
  border-bottom-color: rgba(0, 0, 0, 0.08);
}

body.day-mode .approach-step:hover {
  border-bottom-color: var(--accent-cyan);
}

body.day-mode .case-study-content p,
body.day-mode .feature-card p,
body.day-mode .principle p {
  color: #6e6e73;
}

body.day-mode .stat-label,
body.day-mode .hero-subtitle {
  color: #6e6e73;
}

/* Day Mode Button Styles */
body.day-mode .btn-secondary {
  background: transparent;
  color: #1d1d1f;
  border: 1px solid #1d1d1f;
}

body.day-mode .btn-secondary:hover {
  background: #1d1d1f;
  color: #ffffff;
  border-color: #1d1d1f;
}

/* Day Mode Back to Top Button */
body.day-mode .back-to-top {
  background: var(--accent-gradient);
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(24, 224, 224, 0.3);
}

body.day-mode .back-to-top:hover {
  background: linear-gradient(
    135deg,
    var(--electric-blue) 0%,
    var(--accent-cyan) 100%
  );
  box-shadow: 0 8px 30px rgba(24, 224, 224, 0.5);
}

/* Day Mode - Remove ::after gradients */
body.day-mode .value-proposition::after,
body.day-mode .approach::after,
body.day-mode .how-we-work::after,
body.day-mode .why-Ajentica::after,
body.day-mode .stats::after,
body.day-mode .results::after,
body.day-mode .services::after,
body.day-mode .technologies::after,
body.day-mode .cta::after,
body.day-mode .footer::after {
  background: transparent !important;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  transition: color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Orbital Background Animation */
.orbital-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgba(24, 224, 224, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.orbit-1 {
  width: 300px;
  height: 300px;
  animation: rotateOrbit 20s linear infinite;
  border-color: rgba(24, 224, 224, 0.35);
}

.orbit-2 {
  width: 500px;
  height: 500px;
  animation: rotateOrbit 30s linear infinite reverse;
  border-color: rgba(34, 195, 247, 0.25);
}

.orbit-3 {
  width: 700px;
  height: 700px;
  animation: rotateOrbit 40s linear infinite;
  border-color: rgba(24, 224, 224, 0.18);
}

.orbit::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 10px;
  height: 10px;
  background: var(--accent-cyan);
  border-radius: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 25px var(--accent-cyan), 0 0 10px rgba(24, 224, 224, 0.5);
  animation: pulseNode 2s ease-in-out infinite;
}

.neural-mesh {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(
      circle at 20% 30%,
      rgba(24, 224, 224, 0.03) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 70%,
      rgba(34, 195, 247, 0.03) 0%,
      transparent 50%
    );
}

@keyframes rotateOrbit {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

@keyframes pulseNode {
  0%,
  100% {
    opacity: 1;
    transform: translateX(-50%) scale(1);
  }
  50% {
    opacity: 0.5;
    transform: translateX(-50%) scale(1.5);
  }
}

/* Hero-scoped orbital background (smaller / subtler) */
.orbital-hero {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  display: block;
}

.hero .orbital-hero .orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
}

.hero .orbital-hero .orbit-1 {
  width: 220px;
  height: 220px;
  animation-duration: 18s;
  border-color: rgba(24, 224, 224, 0.28);
}
.hero .orbital-hero .orbit-2 {
  width: 420px;
  height: 420px;
  animation-duration: 26s;
  border-color: rgba(34, 195, 247, 0.20);
}
.hero .orbital-hero .orbit-3 {
  width: 620px;
  height: 620px;
  animation-duration: 34s;
  border-color: rgba(24, 224, 224, 0.15);
}

.hero .orbital-hero .orbit::before {
  width: 6px;
  height: 6px;
  background: var(--accent-cyan);
  box-shadow: 0 0 12px var(--accent-cyan);
}

.hero .orbital-hero .neural-mesh {
  position: absolute;
  inset: 0;
  background: radial-gradient(
      circle at 30% 40%,
      rgba(24, 224, 224, 0.02) 0%,
      transparent 40%
    ),
    radial-gradient(
      circle at 70% 60%,
      rgba(34, 195, 247, 0.02) 0%,
      transparent 40%
    );
}

/* Mobile adjustments: scale down orbital elements to fit narrow (<=480px) designs */
@media (max-width: 480px) {
  /* Reduce the large fixed/background orbits */
  .orbital-background .orbit-1 {
    width: 120px;
    height: 120px;
  }
  .orbital-background .orbit-2 {
    width: 180px;
    height: 180px;
  }
  .orbital-background .orbit-3 {
    width: 260px;
    height: 260px;
  }

  /* Make orbit node smaller and less intense on mobile */
  .orbital-background .orbit::before {
    width: 5px;
    height: 5px;
    box-shadow: 0 0 8px var(--accent-cyan);
  }

  /* Also scale down the hero-scoped orbits so hero section stays compact */
  .hero .orbital-hero .orbit-1 {
    width: 100px;
    height: 100px;
    animation-duration: 12s;
  }
  .hero .orbital-hero .orbit-2 {
    width: 180px;
    height: 180px;
    animation-duration: 18s;
  }
  .hero .orbital-hero .orbit-3 {
    width: 260px;
    height: 260px;
    animation-duration: 24s;
  }

  .hero .orbital-hero .orbit::before {
    width: 4px;
    height: 4px;
    box-shadow: 0 0 8px var(--accent-cyan);
  }

  /* Reduce visual intensity of neural mesh on small screens */
  .orbital-background .neural-mesh,
  .hero .orbital-hero .neural-mesh {
    background: radial-gradient(
        circle at 30% 40%,
        rgba(24, 224, 224, 0.01) 0%,
        transparent 35%
      ),
      radial-gradient(
        circle at 70% 60%,
        rgba(34, 195, 247, 0.01) 0%,
        transparent 35%
      );
  }

  /* Ensure orbits stay centered and don't overflow scrollable area on very small heights */
  .orbital-background,
  .hero .orbital-hero {
    will-change: transform;
  }
}

/* Ensure hero content appears above the orbits */
.hero .container,
.hero .hero-content {
  position: relative;
  z-index: 1;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(24, 224, 224, 0.15);
  transition: transform 0.3s ease-in-out, background 0.3s ease,
    box-shadow 0.3s ease;
  transform: translateY(0);
}

.navbar .container {
  padding: 0 16px;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
}

.logo a {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
  position: relative;
  transition: var(--transition-fast);
}

.logo a::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: var(--transition-smooth);
}

.logo a:hover::after {
  transform: scaleX(1);
  display: none !important;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 40px;
  align-items: center;
}

.nav-menu a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  transition: var(--transition-fast);
  position: relative;
}

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

.nav-menu a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent-cyan);
  transition: var(--transition-smooth);
}

.nav-menu a:hover::after {
  width: 100%;
}

.btn-primary-small {
  padding: 10px 24px !important;
  background: transparent;
  border: 1px solid var(--accent-cyan);
  border-radius: 4px;
  color: var(--accent-cyan) !important;
  font-weight: 600;
  transition: var(--transition-fast);
}

.btn-primary-small:hover {
  background: var(--accent-cyan);
  color: var(--black) !important;
  box-shadow: 0 0 20px rgba(24, 224, 224, 0.4);
}

.btn-primary-small::after {
  display: none !important;
}

.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
}

.mobile-menu-toggle span {
  width: 25px;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition-smooth);
}

/* Logo mark (day/night) */
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Modal (discovery / apply) styles - theme aware */
.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 12000;
  transition: opacity 240ms var(--transition-fast),
    visibility 240ms var(--transition-fast);
}

.modal[aria-hidden="true"] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.modal[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  transition: background 200ms ease;
}

.modal-panel {
  position: relative;
  width: 100%;
  max-width: 720px;
  margin: 0 20px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.02),
    rgba(255, 255, 255, 0.01)
  );
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 20px 22px;
  z-index: 2;
  box-shadow: 0 20px 60px rgba(2, 6, 23, 0.6),
    0 4px 20px rgba(24, 224, 224, 0.04);
  transform: translateY(-6px);
  transition: transform 220ms var(--transition-fast),
    box-shadow 220ms var(--transition-fast);
}

.modal-panel:focus {
  outline: none;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  margin-bottom: 12px;
}

.modal-header h3 {
  font-size: 20px;
  color: var(--text-primary);
}

.modal-close {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 18px;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
}

.modal-close:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.02);
}

.modal-body {
  padding-top: 6px;
}

.modal .form-row {
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
}
.modal label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.modal input[type="text"],
.modal input[type="email"],
.modal textarea {
  width: 100%;
  border-width: 4px !important;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 14px;
  transition: box-shadow 160ms ease, border-color 160ms ease;
}

.modal input:focus,
.modal textarea:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 6px 30px rgba(24, 224, 224, 0.06);
}

.modal .form-actions {
  display: flex;
  flex-direction: row; /* ensure buttons lay out in a row */
  justify-content: center;
  gap: 10px;
  align-items: center;
  margin-top: 6px;
}

.modal .form-status {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 14px;
  display: none;
}

.modal .form-status.success {
  color: #22c55e;
  background-color: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.modal .form-status.error {
  color: #ef4444;
  background-color: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Ensure modal buttons follow site style */
.modal .btn-primary {
  padding: 10px 16px;
  border-radius: 8px;
}
.modal .btn-secondary {
  padding: 10px 14px;
  border-radius: 8px;
}

/* Day mode overrides */
body.day-mode .modal-overlay {
  background: rgba(0, 0, 0, 0.35);
}
body.day-mode .modal-panel {
  background: linear-gradient(180deg, #ffffff, #fafafa);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 12px 40px rgba(15, 15, 15, 0.06);
}
body.day-mode .modal-header {
  border-bottom-color: rgba(0, 0, 0, 0.06);
}
body.day-mode .modal-close {
  color: var(--text-secondary);
}
body.day-mode .modal input[type="text"],
body.day-mode .modal input[type="email"],
body.day-mode .modal textarea {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  color: var(--text-primary);
}

@media (max-width: 520px) {
  .modal-panel {
    margin: 0 12px;
    padding: 16px;
    border-radius: 10px;
  }
  .modal-header h3 {
    font-size: 18px;
  }
}
.logo-mark {
  width: 34px;
  height: 34px;
  object-fit: contain;
  vertical-align: middle;
  margin: 0;
  padding: 0;
}

.logo-day {
  display: none;
}
.logo-night {
  display: inline-block;
}

/* When in day mode, show day logo and hide night logo */
body.day-mode .logo-night {
  display: none;
}
body.day-mode .logo-day {
  display: inline-block;
}

.logo-text {
  font-size: 20px;
  font-weight: 700;
  color: inherit;
  position: relative;
  display: inline-block; /* needed so ::after aligns correctly */
}

.logo-text::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transform-origin: left center;
  transition: var(--transition-smooth);
}

.logo-text:hover::after,
.logo-text:focus::after {
  transform: scaleX(1);
}

.nav-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-controls .nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
}

/* Ensure theme-toggle sits to the right of the menu */
.nav-controls .theme-toggle {
  margin-left: 8px;
}

@media (max-width: 880px) {
  .nav-controls {
    flex-direction: row;
    gap: 10px;
  }
  .nav-controls .nav-menu {
    gap: 16px;
  }
}

@media (max-width: 720px) {
  /* On very small screens, allow nav controls to stack and mobile menu to show */
  /* Keep controls compact: place theme-toggle and other controls inline so hamburger sits next to them */
  .nav-controls {
    flex-direction: row;
    align-items: center;
    gap: 8px;
  }
  .nav-controls .nav-menu {
    display: none;
  }
  .mobile-menu-toggle {
    display: flex;
  }
}

/* Tweak spacing so theme-toggle and hamburger sit adjacent on very small screens */
@media (max-width: 720px) {
  .theme-toggle {
    margin-left: 10px;
  }
  .mobile-menu-toggle {
    margin-left: 3px;
  }
}

/* Mobile menu visible state and hamburger -> X animation */
@media (max-width: 720px) {
  /* when JS toggles .active, show the menu as a dropdown panel */
  .nav-controls .nav-menu.active {
    display: flex !important;
    position: absolute;
    top: 100%;
    right: 16px;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(8px);
    flex-direction: column;
    gap: 8px;
    padding: 12px 14px;
    border-radius: 10px;
    box-shadow: 0 12px 40px rgba(2, 6, 23, 0.6);
    z-index: 1200;
    min-width: 220px;
    align-items: flex-start;
    /* prevent clipping on short viewports */
    max-height: calc(100vh - 110px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-controls .nav-menu.active a {
    display: block;
    padding: 10px 8px;
    width: 100%;
    color: var(--text-secondary);
    font-size: 16px;
  }

  .nav-controls .nav-menu.active a:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
  }

  /* Make the 'Let's Talk' button visible and separated in the mobile menu */
  .nav-controls .nav-menu.active .btn-primary-small {
    display: inline-block;
    padding: 10px 18px !important;
    border: 1px solid var(--accent-cyan) !important;
    color: var(--accent-cyan) !important;
    background: transparent !important;
    margin: 8px 4px 0 4px;
    border-radius: 6px;
  }

  /* If using duplicated .mobile-nav, ensure the button inside it is visible */
  .mobile-nav .btn-primary-small {
    display: inline-block;
    padding: 10px 18px;
    border: 1px solid var(--accent-cyan);
    color: var(--accent-cyan);
    background: transparent;
    margin-top: 8px;
    border-radius: 6px;
  }

  /* Transform hamburger into X when active */
  .mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
  }
  .mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
}

/* Theme Toggle Button */
.theme-toggle {
  position: relative;
  width: 44px;
  height: 44px;
  background: rgba(24, 224, 224, 0.05);
  border: 2px solid rgba(24, 224, 224, 0.2);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  margin-left: 16px;
  padding: 0;
  color: var(--accent-cyan);
}

.theme-toggle:hover {
  border-color: var(--accent-cyan);
  background: rgba(24, 224, 224, 0.15);
  transform: scale(1.08);
  box-shadow: 0 0 20px rgba(24, 224, 224, 0.3);
}

.theme-toggle:active {
  transform: scale(0.95);
}

.theme-toggle svg {
  position: absolute;
  transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-toggle .sun-icon {
  opacity: 0;
  transform: rotate(180deg) scale(0.6);
}

.theme-toggle .moon-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

body.day-mode .theme-toggle .sun-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

body.day-mode .theme-toggle .moon-icon {
  opacity: 0;
  transform: rotate(-180deg) scale(0.6);
}

body.day-mode .theme-toggle {
  border-color: rgba(24, 224, 224, 0.3);
  background: rgba(24, 224, 224, 0.08);
  color: var(--accent-cyan);
}

body.day-mode .theme-toggle:hover {
  border-color: var(--accent-cyan);
  background: rgba(24, 224, 224, 0.2);
  box-shadow: 0 0 20px rgba(24, 224, 224, 0.25);
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: linear-gradient(180deg, #000000 0%, #0a0a1e 50%, #050510 100%);
  padding-top: 80px;
  overflow: hidden;
  transition: background 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    circle,
    rgba(24, 224, 224, 0.08) 0%,
    transparent 70%
  );
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: pulseGlow 4s ease-in-out infinite;
  transition: background 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes pulseGlow {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 0.8;
  }
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 1000px;
  margin: 0 auto;
  padding: 60px 0;
}

.hero-title {
  font-size: clamp(48px, 8vw, 66px);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  color: var(--white);
  animation: fadeInUp 0.8s ease-out;
  letter-spacing: -0.03em;
}

.hero-title::after {
  content: "";
  display: block;
  width: 120px;
  height: 4px;
  background: var(--accent-gradient);
  margin: 24px auto 0;
  border-radius: 2px;
}

.hero-subtitle {
  font-size: clamp(18px, 2.5vw, 24px);
  color: var(--text-secondary);
  margin-bottom: 40px;
  line-height: 1.6;
  animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

.hero-cta {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease-out 0.4s backwards;
}

.btn-primary,
.btn-secondary {
  padding: 16px 40px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none;
  transition: var(--transition-fast);
  display: inline-block;
  font-family: var(--font-heading);
  letter-spacing: 0.02em;
  position: relative;
  overflow: hidden;
}

.btn-primary::before,
.btn-secondary::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.1);
  transition: var(--transition-smooth);
}

.btn-primary:hover::before,
.btn-secondary:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--accent-cyan);
  color: var(--black);
  border: 1px solid var(--accent-cyan);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(24, 224, 224, 0.3);
  background: var(--electric-blue);
  border-color: var(--electric-blue);
}

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

.btn-secondary:hover {
  background: var(--white);
  color: var(--black);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(255, 255, 255, 0.2);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: var(--text-secondary);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 2px;
  animation: fadeIn 1s ease-out 1s backwards;
  font-family: var(--font-heading);
  text-decoration: none;
  cursor: pointer;
}

.hero-scroll-indicator:hover {
  color: var(--text-secondary);
  text-decoration: none;
}

.hero-scroll-indicator:visited {
  color: var(--text-secondary);
  text-decoration: none;
}

.hero-scroll-indicator:focus {
  outline: none;
  color: var(--accent-cyan);
}

.scroll-arrow {
  width: 24px;
  height: 24px;
  margin: 8px auto 0;
  border-left: 2px solid var(--accent-cyan);
  border-bottom: 2px solid var(--accent-cyan);
  transform: rotate(-45deg);
  animation: bounce 2s infinite;
}

/* Value Proposition */
.value-proposition {
  padding: var(--section-padding) 0;
  background: linear-gradient(
    180deg,
    #050510 0%,
    #0a0a1e 30%,
    #0d0d2a 70%,
    #0a0a14 100%
  );
  position: relative;
  transition: background 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.value-proposition::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  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.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.015;
  pointer-events: none;
}

.section-title {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.section-intro {
  font-size: clamp(16px, 1.8vw, 19px);
  color: var(--text-secondary);
  max-width: 800px;
  margin-bottom: 80px;
  line-height: 1.7;
}

.section-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 24px;
  font-family: var(--font-heading);
}

/* About Snapshot - now removed, integrated into value-proposition */

.section-header {
  margin-bottom: 20px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 48px;
}

.feature-card {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  transition: var(--transition-smooth);
  position: relative;
}

.feature-card:hover {
  transform: translateY(-4px);
}

/* Circular icon with gradient background */
.feature-icon-circle {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(24, 224, 224, 0.1);
  border: 2px solid rgba(24, 224, 224, 0.3);
  border-radius: 50%;
  margin-bottom: 32px;
  color: var(--accent-cyan);
  transition: var(--transition-smooth);
}

.feature-card:hover .feature-icon-circle {
  background: rgba(24, 224, 224, 0.2);
  border-color: var(--accent-cyan);
  transform: scale(1.05);
}

.feature-card h3 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.feature-card p {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 15px;
}

/* Services Section */
.services {
  padding: var(--section-padding) 0;
  background: linear-gradient(
    180deg,
    var(--graphite) 0%,
    var(--graphite-light) 30%,
    var(--graphite-dark) 70%,
    var(--black) 100%
  );
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 60px;
}

/* Approach Section */
.approach {
  /* occupy exactly the screen height */
  min-height: 100vh;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0; /* remove section padding; container will have internal padding */
  background: linear-gradient(
    180deg,
    #000000 0%,
    #0a0a1e 25%,
    #0d0d2a 60%,
    #0a0a14 100%
  );
  width: 100%;
  box-sizing: border-box;
}

/* Add viewport-relative padding to the container inside approach so total matches screen height */
.approach .container {
  padding-bottom: 10vh;
  width: 100%;
  box-sizing: border-box;
}

.approach-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 48px;
  padding-top: 0.4vh; /* add vertical spacing from the approach header */
  margin-bottom: 9vh;
}

.approach-step {
  position: relative;
  padding: 15px 0;

  transition: var(--transition-smooth);
}

.approach-step:hover {
  border-bottom-color: var(--accent-cyan);
}

.approach .step-number {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 20px;
  font-family: var(--font-heading);
  letter-spacing: 2px;
  background: rgba(24, 224, 224, 0.1);
  border: 1px solid rgba(24, 224, 224, 0.2);
  border-radius: 50%; /* circular */
  width: 56px;
  height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0; /* size is fixed by width/height */
}

.approach-step h3 {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.approach-step p {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 15px;
}

.service-item {
  position: relative;
}

.service-number {
  font-size: 48px;
  font-weight: 900;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.5;
  margin-bottom: 16px;
}

.service-item h3 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 16px;
}

.service-item > p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.7;
}

.service-details {
  list-style: none;
}

.service-details li {
  padding: 8px 0;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
}

.service-details li:last-child {
  border-bottom: none;
}

.service-details li::before {
  content: "→";
  color: var(--primary-color);
  margin-right: 12px;
  font-weight: 700;
}

/* How We Work / Why Ajentica */
.how-we-work {
  padding: var(--section-padding) 0;
  background: linear-gradient(
    180deg,
    var(--graphite-light) 0%,
    var(--dark-blue) 50%,
    var(--graphite-dark) 100%
  );
}

.why-Ajentica {
  /* occupy exactly the screen height */
  min-height: 100vh;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0; /* container will carry internal spacing */
  background: linear-gradient(180deg, #0a0a14 0%, #0d0d2a 50%, #050510 100%);
  width: 100%;
  box-sizing: border-box;
}

/* Add viewport-relative padding to the container inside why-Ajentica so total matches screen height */
.why-Ajentica .container {
  padding-bottom: 10vh;
  width: 100%;
  box-sizing: border-box;
}

/* add a bit more space above the stats when they're inside the why-Ajentica section */
.why-Ajentica .stats {
  padding-top: 16vh; /* responsive top spacing */
}

.work-principles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 48px;
}

.principle {
  text-align: left;
  position: relative;
  padding: 32px;
  background: rgba(10, 10, 30, 0.4);
  border: 1px solid rgba(24, 224, 224, 0.15);
  border-radius: 2px;
  transition: var(--transition-smooth),
    background 0.6s cubic-bezier(0.4, 0, 0.2, 1),
    border-color 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.principle:hover {
  border-color: var(--accent-cyan);
  background: rgba(24, 224, 224, 0.03);
  transform: translateY(-4px);
}

.principle-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--accent-cyan);
}

.principle-icon svg {
  transition: var(--transition-smooth);
}

.principle:hover .principle-icon svg {
  transform: scale(1.1);
}

.principle h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.principle p {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 15px;
}

/* Stats Section */
.stats {
  padding: 80px 0;
  background: transparent; /* removed decorative background */
  border-top: none;
  border-bottom: none;
  position: relative;
}

.stats::before {
  display: none; /* disable decorative radial */
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 60px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.stat-number {
  font-size: 56px;
  font-weight: 700;
  color: var(--accent-cyan);
  margin-bottom: 12px;
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 15px;
  color: var(--text-secondary);
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Results/Case Studies */
.results {
  background: linear-gradient(180deg, #050510 0%, #0a0a1e 30%, #0d0d2a 100%);
}

.case-studies {
  display: flex;
  flex-direction: column;
  gap: 80px;
}

.case-study {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.case-study:nth-child(even) {
  direction: rtl;
}

.case-study:nth-child(even) > * {
  direction: ltr;
}

.case-study-image {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Healthcare Animation - Enhanced */
.healthcare-animation {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    circle at center,
    rgba(24, 224, 224, 0.03),
    transparent 70%
  );
}

.medical-cross {
  position: relative;
  width: 90px;
  height: 90px;
  z-index: 3;
}

.cross-vertical,
.cross-horizontal {
  position: absolute;
  background: linear-gradient(180deg, var(--electric-blue), var(--accent-cyan));
  border-radius: 6px;
  box-shadow: 0 0 20px rgba(24, 224, 224, 0.4);
}

.cross-vertical {
  width: 16px;
  height: 90px;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  animation: pulse-glow 2s ease-in-out infinite;
}

.cross-horizontal {
  width: 90px;
  height: 16px;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  animation: pulse-glow 2s ease-in-out infinite 0.5s;
}

.data-flow {
  position: absolute;
  width: 3px;
  height: 50px;
  background: linear-gradient(
    to bottom,
    transparent,
    var(--accent-cyan),
    var(--electric-blue),
    transparent
  );
  border-radius: 2px;
  filter: blur(1px);
}

.data-flow-1 {
  top: 15%;
  left: 25%;
  animation: data-stream 2.5s ease-in-out infinite;
}

.data-flow-2 {
  top: 55%;
  right: 20%;
  animation: data-stream 2.5s ease-in-out infinite 0.8s;
  height: 60px;
}

.data-flow-3 {
  top: 35%;
  left: 65%;
  animation: data-stream 2.5s ease-in-out infinite 1.6s;
  height: 45px;
}

.pulse-ring {
  position: absolute;
  border: 3px solid var(--accent-cyan);
  border-radius: 50%;
  opacity: 0;
  animation: pulse-ring 3s ease-out infinite;
  box-shadow: 0 0 15px rgba(24, 224, 224, 0.3);
}

.pulse-ring-1 {
  width: 140px;
  height: 140px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.pulse-ring-2 {
  width: 200px;
  height: 200px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: 1.5s;
  border-width: 2px;
}

/* Education Animation - Enhanced */
.education-animation {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    ellipse at 40% 50%,
    rgba(34, 195, 247, 0.04),
    transparent 65%
  );
}

.brain-network {
  position: relative;
  width: 140px;
  height: 140px;
  z-index: 3;
}

.brain-center {
  position: absolute;
  width: 28px;
  height: 28px;
  background: radial-gradient(circle, var(--accent-cyan), var(--electric-blue));
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: brain-pulse 2.5s ease-in-out infinite;
  box-shadow: 0 0 25px var(--accent-cyan), 0 0 40px rgba(24, 224, 224, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.neural-node {
  position: absolute;
  width: 10px;
  height: 10px;
  background: radial-gradient(circle, var(--electric-blue), var(--accent-cyan));
  border-radius: 50%;
  opacity: 0;
  animation: neural-activation 3.5s ease-in-out infinite;
  box-shadow: 0 0 10px var(--accent-cyan);
}

.node-1 {
  top: 18%;
  left: 28%;
  animation-delay: 0.4s;
}

.node-2 {
  top: 22%;
  right: 22%;
  animation-delay: 0.8s;
}

.node-3 {
  bottom: 28%;
  left: 18%;
  animation-delay: 1.2s;
}

.node-4 {
  bottom: 22%;
  right: 28%;
  animation-delay: 1.6s;
}

.node-5 {
  top: 48%;
  left: 12%;
  animation-delay: 2s;
}

.neural-connection {
  position: absolute;
  height: 3px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--accent-cyan),
    var(--electric-blue),
    transparent
  );
  opacity: 0;
  animation: connection-fire 3.5s ease-in-out infinite;
  transform-origin: left center;
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(24, 224, 224, 0.4);
}

.conn-1 {
  top: 43%;
  left: 38%;
  width: 40px;
  transform: rotate(28deg);
  animation-delay: 0.6s;
}

.conn-2 {
  top: 54%;
  left: 53%;
  width: 36px;
  transform: rotate(-42deg);
  animation-delay: 1s;
}

.conn-3 {
  top: 33%;
  left: 48%;
  width: 32px;
  transform: rotate(58deg);
  animation-delay: 1.4s;
}

.conn-4 {
  bottom: 43%;
  left: 33%;
  width: 45px;
  transform: rotate(-28deg);
  animation-delay: 1.8s;
}

.search-algorithm {
  position: absolute;
  width: 100%;
  height: 100%;
}

.vector-line {
  position: absolute;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--electric-blue),
    var(--accent-cyan),
    transparent
  );
  opacity: 0;
  animation: vector-search 2.8s ease-in-out infinite;
  border-radius: 1px;
  box-shadow: 0 0 6px rgba(34, 195, 247, 0.5);
}

.v-line-1 {
  top: 18%;
  left: 8%;
  width: 70px;
  animation-delay: 0.25s;
}

.v-line-2 {
  top: 68%;
  right: 12%;
  width: 55px;
  animation-delay: 1.1s;
}

.v-line-3 {
  top: 43%;
  left: 68%;
  width: 45px;
  animation-delay: 1.9s;
}

.bm25-indicator {
  position: absolute;
  top: 10%;
  right: 10%;
  width: 16px;
  height: 16px;
  border: 3px solid var(--electric-blue);
  border-radius: 50%;
  opacity: 0;
  animation: bm25-pulse 2.2s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(34, 195, 247, 0.5);
}

.knowledge-particles {
  position: absolute;
  width: 100%;
  height: 100%;
}

.particle {
  position: absolute;
  width: 6px;
  height: 6px;
  background: radial-gradient(circle, var(--accent-cyan), var(--electric-blue));
  border-radius: 50%;
  opacity: 0;
  animation: particle-float 4.5s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(24, 224, 224, 0.6);
}

.p-1 {
  top: 14%;
  left: 14%;
  animation-delay: 0.15s;
}

.p-2 {
  top: 78%;
  left: 23%;
  animation-delay: 1s;
  width: 5px;
  height: 5px;
}

.p-3 {
  top: 28%;
  right: 18%;
  animation-delay: 1.8s;
}

.p-4 {
  bottom: 38%;
  right: 14%;
  animation-delay: 2.6s;
  width: 7px;
  height: 7px;
}

.p-5 {
  top: 58%;
  left: 78%;
  animation-delay: 3.4s;
}

.learning-orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 200px;
  height: 200px;
  border: 2px dashed rgba(24, 224, 224, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.4;
  animation: orbit-rotate 12s linear infinite;
  box-shadow: inset 0 0 20px rgba(24, 224, 224, 0.1);
}

/* Accessibility Animation - Enhanced */
.accessibility-animation {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    ellipse at center,
    rgba(24, 224, 224, 0.04),
    transparent 60%
  );
}

.hand-gesture {
  position: relative;
  width: 80px;
  height: 100px;
  z-index: 3;
}

.hand-outline {
  position: absolute;
  width: 48px;
  height: 68px;
  border: 4px solid var(--accent-cyan);
  border-radius: 24px 24px 12px 12px;
  top: 22px;
  left: 16px;
  animation: hand-glow 2.8s ease-in-out infinite;
  box-shadow: 0 0 20px rgba(24, 224, 224, 0.3),
    inset 0 0 15px rgba(24, 224, 224, 0.1);
}

.finger {
  position: absolute;
  width: 10px;
  height: 28px;
  background: linear-gradient(180deg, var(--accent-cyan), var(--electric-blue));
  border-radius: 5px;
  animation: finger-move 2.2s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(24, 224, 224, 0.5);
}

.finger-1 {
  top: 0;
  left: 22px;
}

.finger-2 {
  top: 4px;
  left: 34px;
  animation-delay: 0.25s;
  height: 30px;
}

.finger-3 {
  top: 9px;
  left: 46px;
  animation-delay: 0.5s;
  height: 26px;
}

.recognition-waves {
  position: absolute;
  width: 100%;
  height: 100%;
}

.wave {
  position: absolute;
  border: 3px solid var(--accent-cyan);
  border-radius: 50%;
  opacity: 0;
  animation: recognition-wave 3.5s ease-out infinite;
  box-shadow: 0 0 15px rgba(24, 224, 224, 0.3);
}

.wave-1 {
  width: 110px;
  height: 110px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.wave-2 {
  width: 160px;
  height: 160px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: 1.2s;
  border-width: 2.5px;
}

.wave-3 {
  width: 210px;
  height: 210px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: 2.4s;
  border-width: 2px;
}

.ai-nodes {
  position: absolute;
  width: 100%;
  height: 100%;
}

.ai-nodes .node {
  position: absolute;
  width: 12px;
  height: 12px;
  background: radial-gradient(circle, var(--electric-blue), var(--accent-cyan));
  border-radius: 50%;
  opacity: 0;
  animation: node-connect 3.8s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(24, 224, 224, 0.6);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.ai-nodes .node-1 {
  top: 18%;
  left: 18%;
}

.ai-nodes .node-2 {
  top: 68%;
  right: 18%;
  animation-delay: 1.2s;
}

.ai-nodes .node-3 {
  top: 28%;
  right: 28%;
  animation-delay: 2.4s;
}

/* Animation Keyframes */
@keyframes pulse-glow {
  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 15px var(--accent-cyan), 0 0 25px rgba(24, 224, 224, 0.3);
  }
  50% {
    opacity: 0.8;
    box-shadow: 0 0 30px var(--accent-cyan), 0 0 45px rgba(24, 224, 224, 0.5),
      0 0 60px rgba(24, 224, 224, 0.2);
  }
}

@keyframes data-stream {
  0% {
    opacity: 0;
    transform: translateY(25px) scale(0.8);
  }
  40% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  60% {
    opacity: 1;
    transform: translateY(-15px) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(-50px) scale(0.6);
  }
}

@keyframes pulse-ring {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.4);
  }
  15% {
    opacity: 0.8;
  }
  30% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.7);
  }
}

@keyframes page-turn {
  0%,
  70% {
    transform: rotateY(0deg);
    opacity: 0.8;
  }
  80% {
    transform: rotateY(-90deg);
    opacity: 0.4;
  }
  90%,
  100% {
    transform: rotateY(-180deg);
    opacity: 0.1;
  }
}

@keyframes brain-pulse {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 0 20px var(--accent-cyan), 0 0 30px rgba(24, 224, 224, 0.2);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.25);
    box-shadow: 0 0 35px var(--accent-cyan), 0 0 50px rgba(24, 224, 224, 0.4),
      0 0 70px rgba(24, 224, 224, 0.2);
  }
}

@keyframes neural-activation {
  0%,
  65% {
    opacity: 0;
    transform: scale(0.3);
  }
  75% {
    opacity: 1;
    transform: scale(1.6);
    box-shadow: 0 0 15px var(--accent-cyan), 0 0 25px rgba(24, 224, 224, 0.4);
  }
  100% {
    opacity: 0;
    transform: scale(1);
  }
}

@keyframes connection-fire {
  0%,
  55% {
    opacity: 0;
    transform: scaleX(0);
  }
  65% {
    opacity: 0.8;
    transform: scaleX(0.6);
  }
  75% {
    opacity: 1;
    transform: scaleX(1);
  }
  100% {
    opacity: 0;
    transform: scaleX(0);
  }
}

@keyframes vector-search {
  0%,
  65% {
    opacity: 0;
    transform: translateX(-25px) scaleX(0.6);
  }
  75% {
    opacity: 0.8;
    transform: translateX(-5px) scaleX(0.9);
  }
  85% {
    opacity: 1;
    transform: translateX(0) scaleX(1);
  }
  100% {
    opacity: 0;
    transform: translateX(25px) scaleX(0.6);
  }
}

@keyframes bm25-pulse {
  0%,
  100% {
    opacity: 0;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1.4);
    box-shadow: 0 0 20px var(--electric-blue), 0 0 35px rgba(34, 195, 247, 0.4);
  }
}

@keyframes particle-float {
  0%,
  75% {
    opacity: 0;
    transform: translateY(15px) scale(0.6);
  }
  85% {
    opacity: 1;
    transform: translateY(-5px) scale(1.1);
  }
  100% {
    opacity: 0;
    transform: translateY(-25px) scale(0.8);
  }
}

@keyframes orbit-rotate {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

@keyframes hand-glow {
  0%,
  100% {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 15px rgba(24, 224, 224, 0.4),
      inset 0 0 12px rgba(24, 224, 224, 0.1);
  }
  50% {
    border-color: var(--electric-blue);
    box-shadow: 0 0 30px rgba(34, 195, 247, 0.5),
      inset 0 0 20px rgba(34, 195, 247, 0.15);
  }
}

@keyframes finger-move {
  0%,
  100% {
    transform: translateY(0) scale(1);
    opacity: 0.85;
  }
  50% {
    transform: translateY(-7px) scale(1.05);
    opacity: 1;
    box-shadow: 0 0 15px rgba(24, 224, 224, 0.6);
  }
}

@keyframes recognition-wave {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.4);
  }
  15% {
    opacity: 0.8;
  }
  30% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.6);
  }
}

@keyframes node-connect {
  0%,
  65% {
    opacity: 0;
    transform: scale(0.4);
  }
  75% {
    opacity: 1;
    transform: scale(1.4);
    box-shadow: 0 0 15px rgba(24, 224, 224, 0.7);
  }
  100% {
    opacity: 0;
    transform: scale(1);
  }
}

.case-tags {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.tag {
  padding: 6px 14px;
  background: transparent;
  border: 1px solid var(--accent-cyan);
  border-radius: 0;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent-cyan);
  font-family: var(--font-heading);
}

.case-study-content h3 {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 16px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.case-study-content p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 24px;
  font-size: 15px;
}

.case-link {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.case-link:hover {
  color: var(--electric-blue);
  gap: 12px;
}

/* Smooth Scroll */
section {
  scroll-margin-top: 80px;
}

/* Selection Color */
::selection {
  background: var(--accent-cyan);
  color: var(--black);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 2px;
}

::-webkit-scrollbar-track {
  background: var(--black);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-cyan);
  border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--electric-blue);
}

/* Technologies */
.technologies {
  padding: 80px 0;
  background: linear-gradient(
    180deg,
    var(--graphite-dark) 0%,
    var(--graphite) 40%,
    var(--graphite-light) 80%,
    var(--dark-blue) 100%
  );
  border-top: 1px solid var(--border-color);
}

.tech-title {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 48px;
}

.tech-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 24px;
}

.tech-item {
  padding: 20px;
  text-align: center;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-weight: 600;
  transition: var(--transition-smooth);
}

.tech-item:hover {
  border-color: var(--primary-color);
  background: rgba(0, 102, 255, 0.1);
  transform: translateY(-4px);
}

/* Engagement Model Section */
.engagement-model {
  padding: var(--section-padding) 0;
  background: linear-gradient(180deg, #000000 0%, #0a0a1e 50%, #000000 100%);
  position: relative;
}

.engagement-models {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 40px;
  margin: 60px 0 80px;
}

.model-card {
  background: rgba(10, 10, 30, 0.4);
  border: 1px solid rgba(24, 224, 224, 0.15);
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.model-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: var(--transition-smooth);
}

.model-card:hover {
  transform: translateY(-8px);
  border-color: var(--primary-color);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.model-card:hover::before {
  transform: scaleX(1);
}

.model-icon {
  width: 80px;
  height: 80px;
  background: rgba(24, 224, 224, 0.1);
  border: 2px solid var(--accent-cyan);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
  margin: 0 auto 24px;
  transition: var(--transition-smooth);
}

.model-card:hover .model-icon {
  background: rgba(24, 224, 224, 0.2);
  transform: scale(1.1);
}

.model-card h3 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  font-family: var(--font-heading);
}

.model-card p {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 24px;
  font-size: 15px;
}

.model-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.feature-badge {
  background: rgba(0, 102, 255, 0.1);
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  transition: var(--transition-fast);
}

.feature-badge:hover {
  background: var(--primary-color);
  color: white;
}

/* Process Section */
.process-section {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 60px 40px;
  position: relative;
}

.process-header {
  text-align: center;
  margin-bottom: 60px;
}

.process-header h3 {
  font-size: 32px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  font-family: var(--font-heading);
}

.process-header p {
  color: var(--text-secondary);
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto;
}

.process-flow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.process-step {
  flex: 1;
  min-width: 180px;
  text-align: center;
  padding: 24px 16px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  transition: var(--transition-smooth);
  position: relative;
}

.process-step:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--accent-cyan);
  transform: translateY(-4px);
}

.step-number {
  width: 48px;
  height: 48px;
  background: rgba(24, 224, 224, 0.1);
  border: 2px solid rgba(24, 224, 224, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 18px;
  color: var(--accent-cyan);
  margin: 0 auto 16px;
  font-family: var(--font-heading);
  transition: var(--transition-smooth);
}

.process-step:hover .step-number {
  background: rgba(24, 224, 224, 0.2);
  border-color: var(--accent-cyan);
  transform: scale(1.05);
}

.step-content h4 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-family: var(--font-heading);
}

.step-content p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

.process-arrow {
  color: var(--accent-cyan);
  opacity: 0.6;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.6;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

/* About Us Section */
.about-us {
  padding: var(--section-padding) 0;
  background: #000000;
  position: relative;
}

/* Vision & Story Section */
.vision-story-section {
  margin-bottom: 100px;
}

.vision-story-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-top: 60px;
}

.vision-card,
.story-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.vision-card::before,
.story-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: var(--transition-smooth);
}

.vision-card:hover,
.story-card:hover {
  transform: translateY(-6px);
  border-color: var(--primary-color);
  background: rgba(255, 255, 255, 0.04);
}

.vision-card:hover::before,
.story-card:hover::before {
  transform: scaleX(1);
}

.card-icon {
  width: 64px;
  height: 64px;
  background: rgba(24, 224, 224, 0.1);
  border: 1px solid var(--accent-cyan);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
  margin: 0 auto 24px;
}

.vision-card h3,
.story-card h3 {
  font-size: 28px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 20px;
  font-family: var(--font-heading);
}

.vision-card p,
.story-card p {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: 16px;
}

/* Section Subheader */
.section-subheader {
  text-align: center;
  margin-bottom: 48px;
}

.section-subheader h3 {
  font-size: 36px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  font-family: var(--font-heading);
}

.section-subheader p {
  color: var(--text-secondary);
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto;
}

/* Leadership Section */
.leadership-section {
  margin-bottom: 100px;
}

.leadership-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 40px;
}

.leader-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 32px;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.leader-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: var(--transition-smooth);
}

.leader-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary-color);
  background: rgba(255, 255, 255, 0.04);
}

.leader-card:hover::before {
  transform: scaleX(1);
}

.leader-avatar {
  flex-shrink: 0;
}

.avatar-placeholder {
  width: 80px;
  height: 80px;
  background: rgba(24, 224, 224, 0.1);
  border: 2px solid rgba(24, 224, 224, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 24px;
  color: var(--accent-cyan);
  font-family: var(--font-heading);
  transition: var(--transition-smooth);
}

.leader-card:hover .avatar-placeholder {
  background: rgba(24, 224, 224, 0.2);
  border-color: var(--accent-cyan);
  transform: scale(1.05);
}

.leader-content {
  flex: 1;
}

.leader-info {
  margin-bottom: 16px;
}

.leader-info h4 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
  font-family: var(--font-heading);
}

.leader-role {
  display: inline-block;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 500;
  font-size: 16px;
}

.leader-card p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 15px;
}

/* Values & Culture Section */
.values-culture-section {
  margin-top: 60px;
}

.values-culture-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.values-section .section-subheader,
.culture-section .section-subheader {
  text-align: left;
  margin-bottom: 32px;
}

.values-section .section-subheader h3,
.culture-section .section-subheader h3 {
  font-size: 32px;
  margin-bottom: 12px;
}

.values-section .section-subheader p,
.culture-section .section-subheader p {
  margin: 0;
  max-width: none;
}

.values-list {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.value-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  transition: var(--transition-smooth);
}

.value-item:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--accent-cyan);
  transform: translateX(8px);
}

.value-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: rgba(24, 224, 224, 0.1);
  border: 1px solid var(--accent-cyan);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
}

.value-content h4 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-family: var(--font-heading);
}

.value-content p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 15px;
}

.culture-list {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.culture-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  transition: var(--transition-smooth);
}

.culture-item:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--accent-cyan);
  transform: translateX(8px);
}

.culture-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: rgba(24, 224, 224, 0.1);
  border: 1px solid var(--accent-cyan);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
}

.culture-content h4 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-family: var(--font-heading);
}

.culture-content p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 15px;
}

/* Careers Section */
.career-hero {
  position: relative;
  padding: 120px 0 80px;
  min-height: 70vh;
  display: flex;
  align-items: center;
  margin-top: 7.5rem;
}

.career-hero-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.career-hero-title {
  font-size: 56px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 24px;
  line-height: 1.2;
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
}

.career-hero-subtitle {
  font-size: 20px;
  color: var(--text-secondary);
  margin-bottom: 48px;
  line-height: 1.6;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.career-hero-stats {
  display: flex;
  justify-content: center;
  gap: 60px;
  margin-top: 48px;
}

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

.hero-stat .stat-number {
  display: block;
  font-size: 24px;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 8px;
  font-family: var(--font-heading);
}

.hero-stat .stat-label {
  font-size: 14px;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.careers {
  background: linear-gradient(
    180deg,
    var(--graphite) 0%,
    var(--graphite-dark) 50%,
    var(--black) 100%
  );
  padding: var(--section-padding) 0;
}

.application-process {
  background: var(--graphite-dark);
  padding: var(--section-padding) 0;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-top: 60px;
}

.process-step {
  text-align: center;
  padding: 40px 20px;
}

.process-step .step-number {
  width: 60px;
  height: 60px;
  background: rgba(24, 224, 224, 0.1);
  border: 2px solid var(--accent-cyan);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  font-size: 18px;
  font-weight: 600;
  color: var(--accent-cyan);
  font-family: var(--font-heading);
}

.process-step h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 16px;
  font-family: var(--font-heading);
}

.process-step p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 14px;
}

.nav-menu a.active {
  color: var(--accent-cyan);
  font-weight: 600;
}

.career-benefits {
  margin-bottom: 80px;
}

/* Modal: Apply Form */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1200;
}

.modal[aria-hidden="false"] {
  display: flex;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.modal-panel {
  position: relative;
  background: var(--black);
  border: 1px solid var(--border-color);
  padding: 28px;
  width: 520px;
  max-width: calc(100% - 40px);
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  z-index: 2;
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 26px;
  cursor: pointer;
}

.apply-form {
  display: grid;
  gap: 12px;
}

.apply-form .form-label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-secondary);
  font-size: 13px;
}

.apply-form input[type="text"],
.apply-form input[type="email"],
.apply-form textarea {
  width: 100%;
  padding: 10px 12px;
  background: var(--graphite);
  border: 1px solid var(--border-color);
  color: var(--white);
}

/* Enhanced File Upload Styles */
.file-upload-container {
  display: block;
  margin-bottom: 16px;
}

.file-upload-area {
  position: relative;
  border: 2px dashed var(--border-color);
  border-radius: 12px;
  padding: 32px 20px;
  text-align: center;
  background: rgba(24, 224, 224, 0.02);
  transition: var(--transition-smooth);
  cursor: pointer;
  overflow: hidden;
}

.file-upload-area::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(24, 224, 224, 0.1),
    transparent
  );
  transition: left 0.8s ease;
}

.file-upload-area:hover {
  border-color: var(--accent-cyan);
  background: rgba(24, 224, 224, 0.05);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(24, 224, 224, 0.15);
}

.file-upload-area:hover::before {
  left: 100%;
}

.file-upload-area.dragover {
  border-color: var(--electric-blue);
  background: rgba(34, 195, 247, 0.08);
  box-shadow: 0 0 30px rgba(34, 195, 247, 0.2);
}

.file-input-hidden {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
  top: 0;
  left: 0;
}

.file-upload-icon {
  color: var(--accent-cyan);
  margin-bottom: 16px;
  display: flex;
  justify-content: center;
  transition: var(--transition-smooth);
}

.file-upload-area:hover .file-upload-icon {
  color: var(--electric-blue);
  transform: scale(1.1);
}

.file-upload-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-upload-primary {
  font-size: 15px;
  color: var(--text-primary);
  font-weight: 500;
}

.file-upload-link {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px solid transparent;
  transition: var(--transition-fast);
}

.file-upload-link:hover {
  border-bottom-color: var(--accent-cyan);
}

.file-upload-secondary {
  font-size: 13px;
  color: var(--text-secondary);
}

.file-upload-status {
  margin-top: 12px;
  padding: 12px 16px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.file-upload-success {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #22c55e;
}

.file-upload-success svg {
  flex-shrink: 0;
}

.uploaded-filename {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Legacy support for existing file inputs */
.file-label {
  display: flex;
  align-items: center;
  gap: 12px;
}

.file-label input[type="file"] {
  display: inline-block;
}

.file-name {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Day mode overrides for file upload */
body.day-mode .file-upload-area {
  background: rgba(24, 224, 224, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
}

body.day-mode .file-upload-area:hover {
  background: rgba(24, 224, 224, 0.08);
  border-color: var(--accent-cyan);
  box-shadow: 0 8px 25px rgba(24, 224, 224, 0.2);
}

body.day-mode .file-upload-status {
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.2);
}

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 6px;
}

.form-status {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 14px;
  display: none;
}

.form-status.success {
  color: #22c55e;
  background-color: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.form-status.error {
  color: #ef4444;
  background-color: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

@media (max-width: 640px) {
  .modal-panel {
    width: 94%;
    padding: 18px;
  }
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px;
  margin-top: 60px;
}

.benefit-card {
  background: var(--graphite-dark);
  padding: 40px;
  border-radius: 0;
  border: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.benefit-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-5px);
}

.benefit-icon {
  width: 60px;
  height: 60px;
  background: rgba(24, 224, 224, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--accent-cyan);
}

.benefit-card h3 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--white);
  font-family: var(--font-heading);
}

.benefit-card p {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: 15px;
}

.open-positions {
  margin-bottom: 80px;
}

.positions-header {
  text-align: center;
  margin-bottom: 60px;
}

.positions-header h3 {
  font-size: 36px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--white);
  font-family: var(--font-heading);
}

.positions-header p {
  color: var(--text-secondary);
  font-size: 18px;
}

.positions-list {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.position-card {
  background: var(--graphite-dark);
  border: 1px solid var(--border-color);
  border-radius: 0;
  padding: 40px;
  transition: var(--transition-smooth);
}

.position-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
}

.position-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.position-info h4 {
  font-size: 24px;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 8px;
  font-family: var(--font-heading);
}

.position-meta {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.position-type,
.position-location {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}

.position-level {
  background: rgba(24, 224, 224, 0.1);
  color: var(--accent-cyan);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.position-description {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 24px;
  font-size: 15px;
}

.position-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 32px;
}

.skill-tag {
  background: transparent;
  border: 1px solid var(--accent-cyan);
  color: var(--accent-cyan);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.position-apply {
  display: inline-flex;
  align-items: center;
  background: var(--accent-cyan);
  color: var(--black);
  padding: 12px 24px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-family: var(--font-heading);
  border: none;
  cursor: pointer;
}

.position-apply:hover {
  background: var(--electric-blue);
  transform: translateY(-2px);
}

.career-cta {
  text-align: center;
  background: rgba(24, 224, 224, 0.05);
  border: 1px solid rgba(24, 224, 224, 0.2);
  border-radius: 0;
  padding: 60px 40px;
}

.career-cta-content h3 {
  font-size: 32px;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 16px;
  font-family: var(--font-heading);
}

.career-cta-content p {
  color: var(--text-secondary);
  font-size: 18px;
  margin-bottom: 32px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

/* CTA Section */
.cta {
  padding: var(--section-padding) 0;
  background: linear-gradient(
    180deg,
    #0a0a1e 0%,
    #000000 30%,
    #050510 70%,
    #0d0d2a 100%
  );
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    circle,
    rgba(24, 224, 224, 0.1) 0%,
    transparent 70%
  );
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: pulseGlow 6s ease-in-out infinite;
}

.cta-content {
  position: relative;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  padding: 80px 40px;
  background: rgba(10, 10, 30, 0.5);
  border: 1px solid rgba(24, 224, 224, 0.2);
  border-radius: 0;
}

.cta-content h2 {
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.cta-content p {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 40px;
  line-height: 1.8;
}

.cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Footer */
.footer {
  padding: 80px 0 40px;
  background: linear-gradient(180deg, #0d0d2a 0%, #000000 100%);
  border-top: 1px solid rgba(24, 224, 224, 0.1);
  margin-top: auto;
}

.footer-logo {
  width: 100%;
  display: flex;
  align-items: center; /* vertical center */
  justify-content: center; /* horizontal center */
  text-align: center;
}

.footer-logo a {
  display: flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  text-decoration: none;
  position: relative;
}

/* intentionally no ::after pseudo-element or hover rules — skip underline effect */
.footer-logo .logo-mark {
  display: inline-block;
  width: 60px;
  height: 60px;
}
.logo-text-footer {
  font-size: 32px;
  font-weight: 700;
  line-height: 1;
}
.logo .logo-mark.logo-night,
.footer-logo .logo-mark.logo-night {
  display: inline-block !important;
}
.logo .logo-mark.logo-day,
.footer-logo .logo-mark.logo-day {
  display: none !important; /* inactive image takes no space */
}

/* day-mode: show day image, remove night image from layout */
body.day-mode .logo .logo-mark.logo-day,
body.day-mode .footer-logo .logo-mark.logo-day {
  display: inline-block !important;
}
body.day-mode .logo .logo-mark.logo-night,
body.day-mode .footer-logo .logo-mark.logo-night {
  display: none !important;
}
.footer-logo .logo-text {
  margin-left: 8px;
  font-weight: 700;
  position: relative;
  display: inline-block;
}
.footer-row {
  display: flex;
  flex-direction: row;
  gap: 20px;
  align-items: flex-start;
  justify-content: flex-start;
  flex-wrap: wrap;
}

.footer-row > .footer-company,
.footer-row > .footer-get-in-touch {
  flex: 1 1 220px;
  min-width: 160px;
}

/* stack on small screens */
@media (max-width: 640px) {
  .footer-row {
    flex-direction: column;
  }
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 60px;
  margin-bottom: 60px;
}

.footer-section h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 20px;
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
}

.footer-section p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 20px;
  font-size: 14px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 12px;
}

.footer-section ul li a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition-fast);
  font-size: 14px;
}

.footer-section ul li a:hover {
  color: var(--accent-cyan);
}

.social-links {
  display: flex;
  gap: 20px;
}

.social-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition-fast);
  font-size: 14px;
  font-weight: 500;
}

.social-links a:hover {
  color: var(--accent-cyan);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 13px;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-links {
  display: flex;
  gap: 32px;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition-fast);
  font-size: 13px;
}

.footer-links a:hover {
  color: var(--accent-cyan);
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0) rotate(-45deg);
  }
  40% {
    transform: translateY(-10px) rotate(-45deg);
  }
  60% {
    transform: translateY(-5px) rotate(-45deg);
  }
}

/* ===============================================
   CONVERSATIONAL SEARCH CHAT WIDGET
   =============================================== */

.chat-widget {
  position: relative;
  bottom: auto;
  right: auto;
  z-index: auto;
  font-family: var(--font-body);
}

.chat-toggle {
  background: var(--accent-gradient);
  color: white;
  border: none;
  border-radius: 50px;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 8px 32px rgba(24, 224, 224, 0.3);
  transition: var(--transition-smooth);
  font-weight: 500;
  font-size: 14px;
}

.chat-toggle:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(24, 224, 224, 0.4);
}

.chat-toggle svg {
  width: 20px;
  height: 20px;
}

.chat-panel {
  position: absolute;
  bottom: 65px;
  right: 0;
  width: 380px;
  height: 500px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  display: none;
  flex-direction: column;
  overflow: hidden;
  backdrop-filter: blur(20px);
}

.chat-panel.active {
  display: flex;
}

.chat-header {
  padding: 12px 24px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(24, 224, 224, 0.08) 0%, rgba(34, 195, 247, 0.05) 100%);
  position: relative;
  overflow: hidden;
}

.chat-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-cyan), transparent);
  animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
  0% { left: -100%; }
  50% { left: 100%; }
  100% { left: 100%; }
}

.chat-title h3 {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 600;
  margin: 0;
  background: linear-gradient(135deg, var(--accent-cyan) 0%, var(--electric-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  position: relative;
  text-shadow: 0 0 20px rgba(24, 224, 224, 0.3);
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.chat-title h3::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(135deg, var(--accent-cyan) 0%, var(--electric-blue) 100%);
  border-radius: 8px;
  opacity: 0;
  filter: blur(8px);
  transition: opacity 0.3s ease;
  z-index: -1;
}

.chat-title h3:hover::before {
  opacity: 0.2;
}

.chat-title h3:hover {
  transform: translateY(-1px);
  text-shadow: 0 0 25px rgba(24, 224, 224, 0.5);
}

.chat-controls {
  display: flex;
  gap: 8px;
}

.chat-control-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 8px;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-control-btn:hover {
  background: var(--border-color);
  color: var(--text-primary);
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-messages::-webkit-scrollbar {
  width: 4px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 2px;
}

.chat-message {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  animation: messageSlideIn 0.3s ease-out;
}

.chat-message.user-message {
  flex-direction: row-reverse;
}

.message-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 4px;
}

.assistant-message .message-avatar {
  background: var(--accent-gradient);
  color: white;
}

.user-message .message-avatar {
  background: var(--grey-medium);
  color: white;
  font-size: 14px;
  font-weight: 600;
}

.message-content {
  max-width: 220px;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
}

.assistant-message .message-content {
  background: rgba(24, 224, 224, 0.1);
  border: 1px solid rgba(24, 224, 224, 0.2);
  color: var(--text-primary);
  border-bottom-left-radius: 4px;
}

.user-message .message-content {
  background: var(--accent-gradient);
  color: white;
  border-bottom-right-radius: 4px;
}

.message-content p {
  margin: 0;
}

.message-content p + p {
  margin-top: 8px;
}

.chat-input-area {
  padding: 16px 24px 20px;
  border-top: 1px solid var(--border-color);
  background: rgba(24, 224, 224, 0.02);
}

.chat-input-container {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

#chat-input {
  flex: 1;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 12px 16px;
  color: var(--text-primary);
  font-size: 16px;
  font-family: var(--font-body);
  resize: none;
  transition: var(--transition-fast);
  -webkit-appearance: none; /* Remove iOS styling */
  appearance: none; /* Remove iOS styling */
  -webkit-border-radius: 12px; /* Ensure consistent border radius on iOS */
  -webkit-text-size-adjust: 100%; /* Prevent text scaling */
  text-size-adjust: 100%; /* Prevent text scaling */
}

#chat-input:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(24, 224, 224, 0.1);
}

#chat-input::placeholder {
  color: var(--text-secondary);
}

#send-message {
  background: var(--accent-gradient);
  border: none;
  border-radius: 12px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
  color: white;
}

#send-message:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(24, 224, 224, 0.3);
}

#send-message:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.chat-status {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-secondary);
  text-align: center;
  min-height: 0;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.chat-status:not(:empty) {
  opacity: 1;
  min-height: 16px;
}

.typing-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 12px;
}

.typing-dots {
  display: flex;
  gap: 2px;
}

.typing-dot {
  width: 4px;
  height: 4px;
  background: var(--accent-cyan);
  border-radius: 50%;
  animation: typingPulse 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(1) { animation-delay: -0.32s; }
.typing-dot:nth-child(2) { animation-delay: -0.16s; }
.typing-dot:nth-child(3) { animation-delay: 0s; }

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes typingPulse {
  0%, 80%, 100% {
    transform: scale(0.8);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Day mode adjustments for chat */
body.day-mode .chat-panel {
  background: var(--bg-light);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

body.day-mode .chat-header {
  background: linear-gradient(135deg, rgba(24, 224, 224, 0.06) 0%, rgba(34, 195, 247, 0.03) 100%);
}

body.day-mode .chat-title h3 {
  background: linear-gradient(135deg, #16b5b5 0%, #1a9ccc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 20px rgba(24, 224, 224, 0.2);
}

body.day-mode .chat-title h3::before {
  background: linear-gradient(135deg, #16b5b5 0%, #1a9ccc 100%);
}

body.day-mode .chat-header::before {
  background: linear-gradient(90deg, transparent, rgba(24, 224, 224, 0.4), transparent);
}

body.day-mode .assistant-message .message-content {
  background: rgba(24, 224, 224, 0.06);
  border-color: rgba(24, 224, 224, 0.15);
}

body.day-mode #chat-input {
  background: white;
  border-color: rgba(0, 0, 0, 0.08);
}

body.day-mode .chat-input-area {
  background: rgba(24, 224, 224, 0.01);
}

/* Tablet responsiveness for chat */
@media (max-width: 1024px) {
  .floating-actions {
    bottom: 20px;
    right: 20px;
    gap: 15px;
  }
  
  .chat-panel {
    width: 360px;
    height: 480px;
  }
}

/* Mobile responsiveness for chat */
@media (max-width: 768px) {
  .floating-actions {
    bottom: 16px !important;
    right: 8px !important;
    gap: 12px;
    flex-direction: column;
  }
  
  .chat-widget {
    position: relative;
  }
  
  /* Prevent viewport scaling when keyboard opens */
  body {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
  
  html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
  
  .chat-panel {
    position: fixed;
    bottom: 0;
    right: 0;
    left: 0;
    width: 100vw;
    height: 70vh;
    max-height: none;
    border-radius: 16px 16px 0 0;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
    z-index: 1001;
  }
  
  .chat-toggle {
    padding: 12px 18px;
    font-size: 13px;
    border-radius: 25px;
  }
  
  .chat-toggle-text {
    display: none;
  }
  
  .back-to-top {
    width: 45px;
    height: 45px;
  }
  
  .chat-messages {
    padding: 12px 16px;
  }
  
  .chat-input-container {
    padding: 12px 16px;
  }
  
  .chat-input-container input,
  #chat-input {
    padding: 12px 16px;
    font-size: 16px !important; /* Prevents zoom on iOS */
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
}

@media (max-width: 480px) {
  .floating-actions {
    bottom: 12px !important;
    right: 8px !important;
    gap: 10px;
  }
  
  .chat-panel {
    height: 75vh;
    border-radius: 12px 12px 0 0;
    z-index: 1001;
  }
  
  .chat-toggle {
    padding: 10px 16px;
    font-size: 12px;
    min-width: 44px; /* Minimum touch target */
    min-height: 44px;
  }
  
  .back-to-top {
    width: 44px;
    height: 44px;
    min-width: 44px; /* Minimum touch target */
    min-height: 44px;
  }
  
  .chat-header {
    padding: 12px 16px;
  }
  
  .chat-messages {
    padding: 8px 12px;
  }
  
  .message-content {
    max-width: calc(100vw - 100px);
    font-size: 14px;
    line-height: 1.5;
  }
  
  .chat-input-container {
    padding: 8px 12px;
  }
  
  .chat-input-container input,
  #chat-input {
    padding: 10px 14px;
    font-size: 16px !important; /* Prevents zoom on iOS */
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
  
  #send-message {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }
}

/* Very small mobile devices */
@media (max-width: 360px) {
  .floating-actions {
    bottom: 8px !important;
    right: 1px !important;
  }
  
  .chat-panel {
    height: 80vh;
    z-index: 1001;
  }
  
  .chat-toggle {
    padding: 8px 12px;
  }
  
  .back-to-top {
    width: 40px;
    height: 40px;
  }
}

/* Mobile Safari viewport height fixes */
@supports (-webkit-touch-callout: none) {
  @media (max-width: 768px) {
    .chat-panel {
      height: 70vh;
      max-height: 70vh; /* Prevent viewport issues on iOS */
    }
  }
  
  @media (max-width: 480px) {
    .chat-panel {
      height: 75vh;
      max-height: 75vh;
    }
  }
}

/* Use dynamic viewport units for modern browsers */
@supports (height: 100dvh) {
  @media (max-width: 768px) {
    .chat-panel {
      height: 70dvh;
      max-height: 70dvh;
    }
  }
  
  @media (max-width: 480px) {
    .chat-panel {
      height: 75dvh;
      max-height: 75dvh;
    }
  }
  
  @media (max-width: 360px) {
    .chat-panel {
      height: 80dvh;
      max-height: 80dvh;
    }
  }
}

/* Landscape mobile orientation */
@media (max-width: 768px) and (orientation: landscape) {
  .chat-panel {
    height: 85vh;
  }
  
  .floating-actions {
    bottom: 12px;
    right: 12px;
  }
}

/* High DPI mobile devices */
@media (max-width: 768px) and (-webkit-min-device-pixel-ratio: 2) {
  .chat-toggle {
    -webkit-tap-highlight-color: transparent;
  }
  
  .back-to-top {
    -webkit-tap-highlight-color: transparent;
  }
  
  .chat-control-btn {
    -webkit-tap-highlight-color: transparent;
  }
  
  #send-message {
    -webkit-tap-highlight-color: transparent;
  }
}

/* Responsive Design */
@media (max-width: 968px) {
  :root {
    --section-padding: 80px;
  }

  .nav-menu {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: var(--black);
    flex-direction: column;
    padding: 48px 24px;
    transition: var(--transition-smooth);
    border-top: 1px solid var(--border-color);
  }

  .nav-menu.active {
    left: 0;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .theme-toggle {
    width: 40px;
    height: 40px;
    margin-left: 10px;
  }

  .theme-toggle svg {
    width: 16px;
    height: 16px;
  }

  .case-study {
    grid-template-columns: 1fr;
  }

  .case-study:nth-child(even) {
    direction: ltr;
  }

  /* Animation scaling for mobile */
  .medical-cross {
    width: 60px;
    height: 60px;
  }

  .cross-vertical {
    width: 10px;
    height: 60px;
  }

  .cross-horizontal {
    width: 60px;
    height: 10px;
  }

  .brain-network {
    width: 100px;
    height: 100px;
  }

  .brain-center {
    width: 16px;
    height: 16px;
  }

  .neural-node {
    width: 6px;
    height: 6px;
  }

  .learning-orbit {
    width: 140px;
    height: 140px;
  }

  .hand-gesture {
    width: 55px;
    height: 75px;
  }

  .hand-outline {
    width: 35px;
    height: 50px;
  }

  .finger {
    width: 6px;
    height: 20px;
  }

  .approach-grid {
    grid-template-columns: 1fr;
  }

  .work-principles {
    grid-template-columns: 1fr;
  }

  /* About Us Responsive */
  .vision-story-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .values-culture-grid {
    grid-template-columns: 1fr;
    gap: 60px;
  }

  .leadership-grid {
    grid-template-columns: 1fr;
  }

  .leader-card {
    flex-direction: column;
    text-align: center;
    gap: 20px;
  }

  /* Careers Responsive */
  .benefits-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .benefit-card {
    padding: 30px;
  }

  .position-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .position-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .career-cta {
    padding: 40px 24px;
  }

  /* Career Hero Responsive */
  .career-hero-title {
    font-size: 40px;
  }

  .career-hero-stats {
    flex-direction: column;
    gap: 32px;
  }

  .process-steps {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  /* Engagement Model Mobile */
  .model-card {
    padding: 24px;
  }

  .model-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 16px;
  }

  .model-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
  }

  .feature-badge {
    font-size: 11px;
    padding: 4px 8px;
  }

  .process-header h3 {
    font-size: 24px;
  }

  .process-step {
    min-width: 150px;
    padding: 16px 12px;
  }

  .step-number {
    width: 40px;
    height: 40px;
    font-size: 16px;
    margin-bottom: 12px;
  }

  .step-content h4 {
    font-size: 16px;
  }

  .step-content p {
    font-size: 13px;
  }
}

/* Smooth Scroll */
section {
  scroll-margin-top: 80px;
}

/* Selection Color */
::selection {
  background: var(--primary-color);
  color: var(--text-primary);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background: var(--darker-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

/* Enhanced Mobile Responsiveness */
@media (max-width: 768px) {
  /* Prevent horizontal scroll */
  body {
    overflow-x: hidden;
  }

  /* Ensure all elements fit within viewport */
  * {
    max-width: 100%;
    box-sizing: border-box;
  }

  /* Typography scaling */
  .hero-title {
    font-size: 36px;
    line-height: 1.2;
    margin-bottom: 20px;
  }

  .hero-subtitle {
    font-size: 18px;
    margin-bottom: 30px;
  }

  .section-title {
    font-size: 32px;
    line-height: 1.3;
    margin-bottom: 16px;
  }

  .section-intro {
    font-size: 16px;
    margin-bottom: 40px;
  }

  /* Card and content spacing */
  .feature-card {
    padding: 24px;
    margin-bottom: 24px;
  }

  .feature-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
  }

  .feature-card p {
    font-size: 14px;
    line-height: 1.6;
  }

  /* Process flow mobile */
  .process-flow {
    flex-direction: column;
    gap: 24px;
  }

  .process-arrow {
    transform: rotate(90deg);
    margin: 12px 0;
  }

  .process-step {
    width: 100%;
  }

  /* Engagement models mobile */
  .engagement-models {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .model-card {
    padding: 24px;
  }

  /* Hero section mobile */
  .hero {
    min-height: 90vh; /* Reduce from 100vh for mobile */
    padding: 80px 0 60px;
  }

  .hero-scroll-indicator {
    bottom: 20px;
    font-size: 10px;
  }

  .scroll-arrow {
    width: 20px;
    height: 20px;
    margin-top: 6px;
  }

  /* Approach section mobile - remove fixed height */
  .approach {
    min-height: auto;
    height: auto;
    padding: var(--section-padding) 0;
  }

  /* Services grid mobile */
  .services-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  /* Stats grid mobile optimization */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .stat-number {
    font-size: 32px;
  }

  .stat-label {
    font-size: 12px;
  }

  /* Case study mobile */
  .case-study-image {
    height: 200px;
  }

  .case-study-content {
    padding: 20px;
  }

  /* Navigation mobile improvements */
  .nav-menu {
    gap: 24px;
    padding: 48px 24px;
  }

  .nav-menu a {
    font-size: 18px;
    padding: 16px 0; /* Larger touch targets */
    display: block;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-menu a:last-child {
    border-bottom: none;
  }

  .mobile-menu-toggle {
    padding: 8px; /* Better touch target */
  }

  .btn-primary-small {
    padding: 12px 20px;
    font-size: 14px;
  }

  /* Footer mobile */
  .footer-content {
    grid-template-columns: 1fr;
    gap: 32px;
    text-align: center;
  }

  .footer-section h4 {
    margin-bottom: 16px;
  }
}

@media (max-width: 480px) {
  /* Extra small mobile devices */
  :root {
    --section-padding: 40px;
  }

  .container {
    padding: 0 16px;
  }

  .hero-title {
    font-size: 28px;
  }

  .section-title {
    font-size: 28px;
  }
  .orbital-hero {
    margin-right: 3px;
    margin-left: 3px;
  }

  .btn-primary,
  .btn-secondary {
    padding: 14px 24px;
    font-size: 14px;
  }

  .feature-card {
    padding: 20px;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }

  .hero-cta {
    gap: 16px;
  }

  /* Leadership cards mobile */
  .leader-card {
    padding: 20px;
    text-align: center;
  }

  .leader-avatar {
    margin: 0 auto 16px;
  }

  /* Values and culture mobile */
  .value-item,
  .culture-item {
    text-align: center;
    gap: 12px;
  }

  .value-icon,
  .culture-icon {
    margin: 0 auto 12px;
  }
}

/* Large Screen Optimizations */
@media (min-width: 1400px) {
  .container {
    max-width: 1600px;
    padding: 0 40px;
  }

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

  .section-intro {
    max-width: 900px;
  }
}

@media (min-width: 1600px) {
  .container {
    max-width: 1800px;
    padding: 0 60px;
  }

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

  .section-intro {
    max-width: 1000px;
  }

  /* Optimize grid layouts for wider screens */
  .capabilities-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
  }

  .approach-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  }

  .tech-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  }
}

/* Ultra-wide screen optimizations */
@media (min-width: 2000px) {
  .container {
    max-width: 2200px;
    padding: 0 80px;
  }

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

  .section-intro {
    max-width: 1200px;
  }
}

/* Smooth section transitions */
section {
  position: relative;
}

/* Add subtle gradient overlays for smoother transitions */
.value-proposition::after,
.approach::after,
.how-we-work::after,
.why-Ajentica::after,
.stats::after,
.results::after,
.services::after,
.technologies::after,
.cta::after,
.footer::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100px;
  background: linear-gradient(transparent 0%, rgba(0, 0, 0, 0.1) 100%);
  pointer-events: none;
  z-index: 0;
}

.value-proposition > *,
.approach > *,
.how-we-work > *,
.why-Ajentica > *,
.stats > *,
.results > *,
.services > *,
.technologies > *,
.cta > *,
.footer > * {
  position: relative;
  z-index: 1;
}

/* Floating Actions Container */
.floating-actions {
  position: fixed;
  bottom: 30px;
  right: 30px;
  display: flex;
  align-items: center;
  gap: 20px;
  z-index: 1000;
}

/* Back to Top Button */
.back-to-top {
  position: relative;
  bottom: auto;
  right: auto;
  width: 50px;
  height: 50px;
  background: var(--accent-gradient);
  border: none;
  border-radius: 50%;
  color: var(--white);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(24, 224, 224, 0.3);
  transition: var(--transition-smooth);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  z-index: 1000;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 30px rgba(24, 224, 224, 0.5);
  background: linear-gradient(
    135deg,
    var(--electric-blue) 0%,
    var(--accent-cyan) 100%
  );
}

.back-to-top:active {
  transform: translateY(-2px);
}

.back-to-top svg {
  transition: var(--transition-fast);
}

.back-to-top:hover svg {
  transform: translateY(-2px);
}

/* =======================================================
   RESPONSIVE ADAPTATIONS (preserves FHD desktop layout)
   ======================================================= */

/* --- Large Tablets / Small Laptops (≤1200px) --- */
@media (max-width: 1200px) {
  .nav-menu {
    gap: 24px;
  }

  .hero-title {
    font-size: clamp(42px, 6vw, 56px);
  }

  .case-study {
    gap: 40px;
  }
}

/* --- Tablets (≤992px) --- */
@media (max-width: 992px) {
  .nav-menu {
    display: none; /* hide normal menu */
  }

  .mobile-menu-toggle {
    display: flex; /* show hamburger */
  }

  .case-study {
    grid-template-columns: 1fr;
  }

  .vision-story-grid {
    grid-template-columns: 1fr;
  }

  .approach,
  .why-Ajentica {
    height: auto;
    min-height: auto;
    padding: 80px 0;
  }

  .engagement-models {
    grid-template-columns: 1fr 1fr;
  }
}

/* --- Mobile Landscape (≤768px) --- */
@media (max-width: 768px) {
  .hero-title {
    font-size: clamp(32px, 8vw, 48px);
  }

  .hero-subtitle {
    font-size: 16px;
    padding: 0 10px;
  }

  .section-title {
    font-size: 32px;
  }

  .features-grid,
  .services-grid,
  .work-principles {
    grid-template-columns: 1fr;
  }

  .case-study {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .engagement-models {
    grid-template-columns: 1fr;
  }

  .process-flow {
    flex-direction: column;
    align-items: stretch;
  }

  .process-step {
    width: 100%;
  }

  .hero-scroll-indicator {
    bottom: 20px;
  }
}

/* ==============================
   MOBILE FULL-WIDTH FIX (≤480px)
   ============================== */
@media (max-width: 480px) {
  /* Allow hero and sections to expand edge-to-edge */
  .container,
  .hero-content {
    width: 100%;
    max-width: none;
    padding-left: 16px;
    padding-right: 16px;
  }

  /* Buttons take full width */
  .hero-cta a.btn-primary,
  .hero-cta a.btn-secondary,
  .btn-primary,
  .btn-secondary {
    width: 100%;
    text-align: center;
    box-sizing: border-box;
  }

  /* Ensure text doesn’t squeeze too much */
  .hero-title {
    font-size: 26px;
    line-height: 1.2;
  }

  .hero-subtitle {
    font-size: 14px;
    padding: 0 8px;
  }

  /* Avoid overflow from background layers */
  .hero::before,
  .hero .orbital-hero {
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
  }

  /* Prevent horizontal scrollbars */
  body {
    overflow-x: hidden;
  }
}

/* ===========================================================
   SECTION OVERLAP FIX (preserves FHD look)
   =========================================================== */

/* Fix sections that currently use fixed viewport height */
.hero,
.approach,
.why-Ajentica {
  min-height: 100vh; /* fill full screen if content short */
  height: auto; /* allow growth if content taller */
  position: relative; /* keeps z-index and stacking sane */
  overflow: hidden; /* contain internal visuals */
}

/* Ensure each section visually separates from the next */
section {
  position: relative;
  z-index: 1;
  margin: 0;
  padding-top: 80px; /* space below fixed navbar */
  padding-bottom: 80px; /* space before next section */
}

/* Prevent background orbits or meshes from covering next sections */
.orbital-background,
.orbital-hero,
.neural-mesh {
  z-index: 0;
  pointer-events: none;
}

/* Ensure internal .container never overlaps next section */
.container {
  position: relative;
  z-index: 1;
}

/* Mobile-specific safeguard: stack sections cleanly */
@media (max-width: 768px) {
  .hero,
  .approach,
  .why-Ajentica {
    min-height: auto;
    padding-top: 100px; /* more breathing room */
    padding-bottom: 100px;
  }

  section {
    padding-top: 60px;
    padding-bottom: 60px;
  }
}

/* Mobile controls: keep theme toggle and hamburger together on small screens */
@media (max-width: 720px) {
  .mobile-controls {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    justify-content: flex-end; /* keep controls on the right like desktop */
  }

  /* remove any large left margins on the theme toggle so items sit tightly */
  .mobile-controls .theme-toggle {
    margin-left: 0 !important;
    padding: 6px;
  }

  /* ensure hamburger has a small left offset and stays tappable */
  .mobile-controls .mobile-menu-toggle {
    margin-left: 6px !important;
    padding: 8px;
  }

  /* slightly reduce CTA size within the mobile-controls if present */
  .mobile-controls .btn-primary-small {
    padding: 6px 10px;
    font-size: 13px;
  }
}

/* Footer: center company & contact blocks on small screens */
@media (max-width: 720px) {
  .footer .footer-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
  }

  .footer .footer-company,
  .footer .footer-get-in-touch {
    width: 100%;
    text-align: center;
    display: block;
    margin: 0 auto;
  }

  /* Center lists and links inside those blocks */
  .footer .footer-company ul,
  .footer .footer-get-in-touch ul {
    list-style: none;
    padding: 0;
    margin: 8px 0 0 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .footer .footer-company a,
  .footer .footer-get-in-touch a {
    display: inline-block;
    text-align: center;
  }
}
