/* ==========================================================================
   Neurons AI - Custom Styles
   Modern Clean SaaS with 3D Minimalism
   ========================================================================== */

/* ==========================================================================
   CSS Custom Properties
   ========================================================================== */
:root {
  --color-primary: #0f172a;
  --color-secondary: #1e293b;
  --color-accent: #3b82f6;
  --color-accent-dark: #1d4ed8;
  --color-surface: #ffffff;
  --color-background: #f8fafc;
  --color-text: #475569;
  --color-text-light: #94a3b8;
  --color-border: #e2e8f0;

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);

  --transition-fast: 150ms ease;
  --transition-normal: 300ms ease;
  --transition-slow: 500ms ease;
}

/* ==========================================================================
   Base Resets & Typography
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-background);
}

/* Selection styling */
::selection {
  background-color: var(--color-accent);
  color: white;
}

/* ==========================================================================
   Glassmorphism Effect
   ========================================================================== */
.glass-effect {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.glass-dark {
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   Navigation
   ========================================================================== */
header {
  transition: box-shadow var(--transition-normal), background-color var(--transition-normal);
}

header.scrolled {
  box-shadow: var(--shadow-lg);
  background: rgba(255, 255, 255, 0.95);
}

/* Mobile menu */
#mobile-menu {
  transform: translateX(-100%);
  transition: transform var(--transition-normal);
}

#mobile-menu.open {
  transform: translateX(0);
}

/* Hamburger menu animation */
.hamburger-line {
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.hamburger.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active .hamburger-line:nth-child(2) {
  opacity: 0;
}

.hamburger.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

/* ==========================================================================
   Navigation Links
   ========================================================================== */
.nav-link {
  position: relative;
  color: #475569;
  font-weight: 500;
  padding: 0.5rem 0;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--transition-normal);
}

.nav-link:hover {
  color: var(--color-primary);
}

.nav-link:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* ==========================================================================
   Buttons & Interactive Elements
   ========================================================================== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 0.875rem 1.75rem;
  background: linear-gradient(135deg, var(--color-primary) 0%, #1e3a8a 100%);
  color: white;
  font-weight: 600;
  border-radius: 9999px;
  box-shadow: 0 4px 14px 0 rgba(15, 23, 42, 0.2);
  position: relative;
  overflow: hidden;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left var(--transition-slow);
}

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

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px 0 rgba(15, 23, 42, 0.3);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 0.875rem 1.75rem;
  background: transparent;
  color: var(--color-primary);
  font-weight: 600;
  border: 2px solid var(--color-primary);
  border-radius: 9999px;
  transition: background-color var(--transition-fast), transform var(--transition-fast);
}

.btn-secondary:hover {
  background-color: var(--color-background);
  transform: translateY(-1px);
}

/* ==========================================================================
   Product Cards
   ========================================================================== */
.product-card {
  background: white;
  border-radius: 1.5rem;
  padding: 1.5rem;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
}

/* ==========================================================================
   Cards
   ========================================================================== */
.card {
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.card-3d {
  transform-style: preserve-3d;
  perspective: 1000px;
}

.card-3d:hover {
  transform: translateY(-8px) rotateX(2deg);
}

/* ==========================================================================
   Two Pillars Section - Stacked Layout
   ========================================================================== */

/* Converted tab buttons to anchor links */
.tab-link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 2rem;
  font-weight: 600;
  color: var(--color-text);
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 9999px;
  cursor: pointer;
  position: relative;
  transition: all var(--transition-normal);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}

.tab-link:hover {
  color: var(--color-primary);
  border-color: var(--color-accent);
  background: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.tab-link svg {
  color: var(--color-accent);
  transition: transform var(--transition-fast);
}

.tab-link:hover svg {
  transform: scale(1.1);
}

.tab-link:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}


/* Stacked Sections */
.section-stacked {
  scroll-margin-top: 120px;
  /* Offset for sticky header */
  margin-bottom: 4rem;
  /* Spacing between stacked sections */
  animation: fadeIn var(--transition-normal) ease-out;
}

.section-stacked:last-child {
  margin-bottom: 0;
}

.section-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 2.25rem;
  /* Increased size */
  line-height: 2.5rem;
  color: #0f172a;
  margin-bottom: 3rem;
  text-align: center;
  display: block;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 6px;
  background: linear-gradient(to right, var(--color-accent), var(--color-accent-dark));
  border-radius: 99px;
  margin: 1rem auto 0;
}

/* Removed ::before sidebar */

/* ==========================================================================
   Animations
   ========================================================================== */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes float {

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

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

@keyframes pulse-glow {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
  }

  50% {
    box-shadow: 0 0 0 15px rgba(59, 130, 246, 0);
  }
}

@keyframes bounce-subtle {

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

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

/* Animation classes */
.animate-fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease-out forwards;
}

.animate-fade-in-down {
  animation: fadeInDown 0.6s ease-out forwards;
}

.animate-fade-in-left {
  animation: fadeInLeft 0.6s ease-out forwards;
}

.animate-fade-in-right {
  animation: fadeInRight 0.6s ease-out forwards;
}

.animate-scale-in {
  animation: scaleIn 0.5s ease-out forwards;
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

.animate-pulse-glow {
  animation: pulse-glow 2s ease-in-out infinite;
}

.animate-bounce-subtle {
  animation: bounce-subtle 2s ease-in-out infinite;
}

/* Scroll-triggered animation states */
.scroll-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.scroll-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered animation delays */
.delay-100 {
  animation-delay: 100ms;
}

.delay-200 {
  animation-delay: 200ms;
}

.delay-300 {
  animation-delay: 300ms;
}

.delay-400 {
  animation-delay: 400ms;
}

.delay-500 {
  animation-delay: 500ms;
}

.delay-600 {
  animation-delay: 600ms;
}

.delay-700 {
  animation-delay: 700ms;
}

.delay-800 {
  animation-delay: 800ms;
}

/* ==========================================================================
   Floating Chat Button
   ========================================================================== */
.floating-chat {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
}

.floating-chat-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.floating-chat-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

.floating-chat-btn svg {
  width: 32px;
  height: 32px;
  fill: white;
}

/* Chat tooltip */
.chat-tooltip {
  position: absolute;
  right: 70px;
  top: 50%;
  transform: translateY(-50%);
  background: white;
  padding: 8px 16px;
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-fast), visibility var(--transition-fast);
}

.floating-chat:hover .chat-tooltip {
  opacity: 1;
  visibility: visible;
}

.chat-tooltip::after {
  content: '';
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  border: 4px solid transparent;
  border-left-color: white;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-visual {
  position: relative;
}

.hero-visual::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -20%;
  width: 140%;
  height: 140%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
  pointer-events: none;
}

.dashboard-mockup {
  position: relative;
  z-index: 1;
}

.floating-card {
  position: absolute;
  background: white;
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: var(--shadow-xl);
  animation: float 4s ease-in-out infinite;
}

.floating-card-1 {
  top: 10%;
  right: -10%;
  animation-delay: 0s;
}

.floating-card-2 {
  bottom: 20%;
  left: -5%;
  animation-delay: 1s;
}

.floating-card-3 {
  top: 40%;
  right: -15%;
  animation-delay: 2s;
}

/* ==========================================================================
   Stats Counter Animation
   ========================================================================== */
.stat-number {
  display: inline-block;
}

.stat-number.counting {
  animation: countPulse 0.1s ease-in-out;
}

@keyframes countPulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }
}

/* ==========================================================================
   Trust Section - Logo Slider
   ========================================================================== */
.logo-slider {
  overflow: hidden;
  position: relative;
}

.logo-slider::before,
.logo-slider::after {
  content: '';
  position: absolute;
  top: 0;
  width: 100px;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.logo-slider::before {
  left: 0;
  background: linear-gradient(to right, var(--color-background), transparent);
}

.logo-slider::after {
  right: 0;
  background: linear-gradient(to left, var(--color-background), transparent);
}

.logo-track {
  display: flex;
  animation: scroll 30s linear infinite;
}

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

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

.logo-track:hover {
  animation-play-state: paused;
}

/* Logo carousel items */
.logo-item {
  flex-shrink: 0;
  width: 180px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  margin: 0 1rem;
  background: transparent;
  border-radius: 1rem;
  border: none;
}

.logo-item img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.6;
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.logo-item:hover img {
  filter: grayscale(0%);
  opacity: 1;
}

@media (max-width: 768px) {
  .logo-item {
    width: 140px;
    height: 60px;
    margin: 0 0.5rem;
  }
}

/* ==========================================================================
   Workflow Section - Timeline
   ========================================================================== */
.workflow-line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-border), transparent);
}

.workflow-step {
  position: relative;
  z-index: 1;
}

.workflow-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--color-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
  margin: 0 auto 1rem;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.workflow-step:hover .workflow-number {
  transform: scale(1.1);
  box-shadow: 0 0 0 8px rgba(15, 23, 42, 0.1);
}

/* ==========================================================================
   Form Styles
   ========================================================================== */
.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--color-border);
  border-radius: 12px;
  font-size: 1rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  background: white;
}

.form-input:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.form-input::placeholder {
  color: var(--color-text-light);
}

/* ==========================================================================
   Skip to Main Content (Accessibility)
   ========================================================================== */
.skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-primary);
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  z-index: 9999;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 16px;
}

/* ==========================================================================
   Focus Indicators (Accessibility)
   ========================================================================== */
*:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
  .floating-card {
    display: none;
  }

  .floating-chat {
    bottom: 16px;
    right: 16px;
  }

  .floating-chat-btn {
    width: 52px;
    height: 52px;
  }

  .chat-tooltip {
    display: none;
  }

  .logo-slider::before,
  .logo-slider::after {
    width: 50px;
  }
}

@media (max-width: 640px) {
  .tab-btn {
    padding: 12px 16px;
    font-size: 0.875rem;
  }

  .workflow-line {
    display: none;
  }
}

/* ==========================================================================
   Reduced Motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  .logo-track {
    animation: none;
  }

  .floating-card {
    animation: none;
  }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */
@media print {

  header,
  .floating-chat,
  .skip-link {
    display: none !important;
  }

  body {
    background: white;
    color: black;
  }

  a {
    text-decoration: underline;
  }
}