/* ==========================================================================
   Design System & Variables
   ========================================================================== */
:root {
  --color-primary: #0B3686; /* Deep blue */
  --color-accent: #145FEC; /* Vibrant blue */
  --color-accent-hover: #0d46b8;
  --color-accent-highlight: #00E5FF; /* Cyan for high contrast on dark */
  --color-accent-light: #6BB0FF; /* Light blue for readability on dark */
  --color-gray-light: #EDEDED;
  --color-white: #FFFFFF;
  --color-bg-dark: #030F26;
  --color-node-bg: #0B1C3D;
  --color-text-dark: #0B3686;
  --color-text-muted: #4A639A;

  --font-main: 'Alexandria', sans-serif;
  
  --shadow-sm: 0 4px 6px -1px rgba(11, 54, 134, 0.05), 0 2px 4px -1px rgba(11, 54, 134, 0.03);
  --shadow-md: 0 10px 15px -3px rgba(11, 54, 134, 0.08), 0 4px 6px -2px rgba(11, 54, 134, 0.04);
  --shadow-lg: 0 20px 25px -5px rgba(11, 54, 134, 0.1), 0 10px 10px -5px rgba(11, 54, 134, 0.04);
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 24px;
  
  --transition-fast: 150ms ease;
  --transition-smooth: 300ms ease;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-main);
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text-dark);
  background-color: var(--color-bg-dark);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1.5rem;
  color: var(--color-text-muted);
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-accent-hover);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 6rem 0;
}

.section-bg-light {
  background-color: #F4F7FB;
  color: var(--color-bg-dark);
}

.section-bg-light,
.section-bg-light h1, 
.section-bg-light h2, 
.section-bg-light h3, 
.section-bg-light h4, 
.section-bg-light p,
.section-bg-light .step-title {
  color: var(--color-bg-dark) !important;
}

.section-bg-light .n8n-node {
  background: #F0F4F8 !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.section-bg-light .n8n-node:hover {
  border-color: rgba(0, 0, 0, 0.1) !important;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05) !important;
  transform: translateY(-4px);
}

.section-bg-light .n8n-node p,
.section-bg-light .n8n-node h3,
.section-bg-light .n8n-node strong {
  color: var(--color-bg-dark) !important;
}

.section-bg-light .step-number {
  color: var(--color-primary) !important;
}


.section-bg-dark {
  background-color: var(--color-bg-dark);
  color: var(--color-white);
}

.section-bg-dark h1, 
.section-bg-dark h2, 
.section-bg-dark h3, 
.section-bg-dark p {
  color: var(--color-white);
}


/* Utility Classes */
.text-highlight {
  color: var(--color-accent-highlight) !important;
}
.text-accent-light {
  color: var(--color-accent-light) !important;
}
.text-white {
  color: var(--color-white) !important;
}
.bg-glass {
  background: rgba(20, 95, 236, 0.15);
  border: 1px solid rgba(20, 95, 236, 0.3);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* ==========================================================================
   Components
   ========================================================================== */

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 1.75rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition-smooth);
  border: 2px solid transparent;
  text-align: center;
  min-height: 44px;
}

.btn-primary {
  background-color: var(--color-accent);
  color: var(--color-white);
}

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

.btn-secondary {
  background-color: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

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


.btn-dark {
  background-color: var(--color-primary);
  color: var(--color-white);
}

.btn-dark:hover {
  background-color: var(--color-bg-dark);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-white {
  background-color: var(--color-white);
  color: var(--color-bg-dark);
}

.btn-white:hover {
  background-color: var(--color-gray-light);
  color: var(--color-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Header & Navigation */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(3, 15, 38, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 1000;
  border-bottom: 1px solid transparent;
  transition: all var(--transition-smooth);
  padding: 1.5rem 0;
}

.site-header.scrolled {
  padding: 1rem 0;
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--color-gray-light);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#logo-slot {
  height: 48px;
  display: flex;
  align-items: center;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--color-primary);
  /* Placeholder styling if SVG is absent */
  text-transform: lowercase;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  color: var(--color-text-dark);
  font-weight: 400;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--color-accent);
  transition: width var(--transition-smooth);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-link.active {
  font-weight: 700;
  color: var(--color-accent);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-menu-icon {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-primary);
  position: relative;
  transition: background-color var(--transition-fast);
}

.mobile-menu-icon::before,
.mobile-menu-icon::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background-color: var(--color-primary);
  left: 0;
  transition: transform var(--transition-smooth);
}

.mobile-menu-icon::before {
  top: -8px;
}

.mobile-menu-icon::after {
  bottom: -8px;
}

/* Hero Section */
.hero {
  padding-top: 10rem;
  padding-bottom: 6rem;
  display: flex;
  align-items: center;
  min-height: 80vh;
  position: relative;
  overflow: hidden;
}

.hero-container {
  position: relative;
  z-index: 10;
}

/* Animated Nodes Background for Hero */
.nodes-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.nodes-svg {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

.node-line {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: drawLine 3s ease-out forwards;
}

.node-line-2 {
  animation-delay: 1s;
}

.node {
  position: absolute;
  width: 16px;
  height: 16px;
  background-color: var(--color-accent);
  border-radius: 50%;
  box-shadow: 0 0 15px var(--color-accent);
  opacity: 0;
  animation: pulseNode 3s infinite;
}

.node.n1 { top: 80%; left: 10%; animation-delay: 0.5s; opacity: 1; }
.node.n2 { top: 50%; left: 40%; animation-delay: 1.5s; opacity: 1; }
.node.n3 { top: 30%; left: 80%; animation-delay: 2.5s; opacity: 1; }
.node.n4 { top: 20%; left: 20%; animation-delay: 1s; opacity: 1; }

@keyframes drawLine {
  to { stroke-dashoffset: 0; }
}

@keyframes pulseNode {
  0% { box-shadow: 0 0 0 0 rgba(20, 95, 236, 0.6); transform: scale(1); }
  70% { box-shadow: 0 0 0 20px rgba(20, 95, 236, 0); transform: scale(1.1); }
  100% { box-shadow: 0 0 0 0 rgba(20, 95, 236, 0); transform: scale(1); }
}

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

.hero .lead {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  max-width: 600px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.card {
  background-color: var(--color-bg-dark);
  border-radius: var(--radius-md);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-smooth);
  border: 1px solid var(--color-gray-light);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: var(--shadow-md);
}

.card-icon {
  color: var(--color-primary);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background-color: rgba(11, 54, 134, 0.05);
  border-radius: var(--radius-sm);
}

.card-title {
  margin-bottom: 1rem;
}

.card-text {
  margin-bottom: 0;
  flex-grow: 1;
}

/* Process Section */
.process-flow {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin: 4rem 0;
  position: relative;
}

.process-flow::before {
  content: '';
  position: absolute;
  top: 24px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-gray-light);
  z-index: 1;
}

.process-step {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
  padding: 0 1rem;
}

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

.step-title {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
}

/* Detailed Process Steps (Page Process) */
.process-detail-step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 6rem;
}

.process-detail-step:nth-child(even) {
  direction: rtl;
}

.process-detail-step:nth-child(even) > * {
  direction: ltr;
}

.process-meta {
  display: flex;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.meta-item {
  display: flex;
  flex-direction: column;
}

.meta-label {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.meta-value {
  color: var(--color-text-muted);
}

/* Testimonials */
.testimonial-card {
  background-color: var(--color-bg-dark);
  border-radius: var(--radius-md);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-gray-light);
  position: relative;
}

.testimonial-quote {
  font-size: 1.125rem;
  font-style: italic;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 2;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.author-info h4 {
  margin-bottom: 0.25rem;
  font-size: 1rem;
}

.author-info p {
  margin-bottom: 0;
  font-size: 0.875rem;
}

/* Contact Form */
.contact-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 4rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--color-white);
}

.form-control {
  width: 100%;
  padding: 1rem;
  border: 1px solid var(--color-gray-light);
  border-radius: var(--radius-sm);
  font-family: var(--font-main);
  font-size: 1rem;
  transition: border-color var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(20, 95, 236, 0.1);
}

textarea.form-control {
  min-height: 150px;
  resize: vertical;
}

.form-note {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-top: 1rem;
}

.contact-info {
  background-color: var(--color-gray-light);
  padding: 2.5rem;
  border-radius: var(--radius-md);
  color: var(--color-bg-dark);
}

.contact-info h4, 
.contact-info p, 
.contact-info a {
  color: var(--color-bg-dark) !important;
}

.info-item {
  margin-bottom: 2rem;
}

.info-item h4 {
  margin-bottom: 0.5rem;
}

/* Footer */
.site-footer {
  background-color: var(--color-primary);
  color: var(--color-white);
  padding: 4rem 0 2rem;
}

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

#footer-logo-slot {
  height: 40px;
  display: flex;
  align-items: center;
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 1rem;
  color: var(--color-white);
}

.footer-text {
  color: rgba(255, 255, 255, 0.7);
}

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

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  text-align: center;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.5);
}

/* Animations & Utilities */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

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

.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }

/* Responsive Adjustments */
@media (max-width: 1024px) {
  h1 { font-size: 3rem; }
  .process-detail-step, .contact-grid {
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 72px;
    left: 0;
    width: 100%;
    background-color: var(--color-bg-dark);
    flex-direction: column;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-smooth);
  }
  
  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .mobile-menu-btn {
    display: block;
  }

  .process-flow {
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
  }

  .process-flow::before {
    top: 0;
    left: 24px;
    width: 2px;
    height: 100%;
  }

  .process-step {
    flex-direction: row;
    text-align: left;
    gap: 1.5rem;
    padding: 0;
  }
  
  .step-number {
    margin-bottom: 0;
  }

  .process-detail-step {
    grid-template-columns: 1fr;
  }
  
  .process-detail-step:nth-child(even) {
    direction: ltr;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }
  .section { padding: 4rem 0; }
  .hero { padding-top: 8rem; padding-bottom: 4rem; }
  .hero-actions { flex-direction: column; width: 100%; }
  .btn { width: 100%; }
}

/* Futuristic Grid Background */
body.n8n-theme {
  background-color: var(--color-bg-dark);
  background-image: linear-gradient(rgba(20, 95, 236, 0.05) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(20, 95, 236, 0.05) 1px, transparent 1px);
  background-size: 30px 30px;
  background-position: center top;
  color: var(--color-white);
}

.n8n-theme .nav-link { color: var(--color-white); }
.n8n-theme h1, .n8n-theme h2, .n8n-theme h3, .n8n-theme h4, .n8n-theme h5, .n8n-theme h6 { color: var(--color-white); }
.n8n-theme .card-text, .n8n-theme p { color: rgba(255, 255, 255, 0.7); }
.n8n-theme .step-title { color: var(--color-white); }
.n8n-theme .btn-secondary { color: var(--color-white); border-color: var(--color-white); }

/* Scroll Workflow SVG */
.workflow-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.workflow-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 4px;
  background: rgba(20, 95, 236, 0.1);
  transform: translateX(-50%);
}

.workflow-line-progress {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--color-accent);
  box-shadow: 0 0 15px var(--color-accent), 0 0 30px var(--color-accent);
  height: 0%;
  transition: height 0.1s ease-out;
}

@media (max-width: 1024px) {
  .workflow-line { left: 20px; }
}

/* N8N Node Cards */
.n8n-node {
  background: #0B1C3D !important; /* Deep rich navy, elegant ton-sur-ton */
  border: 1px solid rgba(255, 255, 255, 0.05) !important;
  position: relative;
  border-radius: var(--radius-md) !important;
  z-index: 2;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  overflow: hidden;
}

.n8n-node:hover {
  background: #0F2552 !important; /* Slightly lighter on hover */
  border-color: rgba(255, 255, 255, 0.15) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(20, 95, 236, 0.1) !important; /* Subtle glow */
  transform: translateY(-4px);
}

.n8n-node h2,
.n8n-node h3,
.n8n-node strong {
  color: var(--color-white) !important;
}

.n8n-node p {
  color: rgba(255, 255, 255, 0.8) !important;
  font-size: 1.125rem !important;
  line-height: 1.6 !important;
}

.n8n-node .card-icon {
  color: var(--color-accent-light) !important;
  background-color: rgba(255, 255, 255, 0.05) !important;
}

main {
  position: relative;
}

.n8n-theme .card-icon {
  color: var(--color-white);
  background-color: rgba(255, 255, 255, 0.1);
  width: 64px;
  height: 64px;
}
.n8n-theme .card-icon svg {
  width: 36px;
  height: 36px;
}

/* Automation Interactive Section */
.automation-tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.tab-btn {
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--color-white);
  padding: 1rem 2rem;
  border-radius: 50px;
  cursor: pointer;
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 1.125rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}
.tab-btn:hover {
  background-color: rgba(255, 255, 255, 0.05);
}
.tab-btn.active {
  background-color: var(--color-primary);
  border-color: var(--color-accent);
  color: var(--color-white);
  box-shadow: 0 0 20px rgba(20, 95, 236, 0.6);
  transform: translateY(-2px);
}

.automation-desc {
  display: none;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2rem;
  border-radius: var(--radius-md);
  animation: fadeIn 0.5s ease;
}
.automation-desc.active {
  display: block;
}

.diagram-area {
  position: relative;
  width: 100%;
  height: 460px;
  background-color: var(--color-bg-dark);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: visible; /* Prevent bubble clipping */
  margin-top: 2.5rem;
}

/* Base grid for the diagram */
.diagram-area::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(20, 95, 236, 0.15) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 20px 20px;
  pointer-events: none;
  border-radius: var(--radius-md);
}

.diagram-container {
  position: relative;
  width: 100%;
  height: 100%;
}

.diagram-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.diagram-node {
  position: absolute;
  width: 90px;
  height: 90px;
  background-color: var(--color-white);
  border: 2px solid var(--color-white);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 10;
  color: var(--color-bg-dark);
}
.diagram-node.active-node {
  border-color: rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
  transform: translate(-50%, -50%) scale(1.1);
}
.diagram-node svg {
  width: 48px;
  height: 48px;
}
.diagram-node .node-label {
  position: absolute;
  bottom: -30px;
  white-space: nowrap;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-white);
  background-color: rgba(0,0,0,0.5);
  padding: 2px 6px;
  border-radius: 4px;
}

/* Diagram node bubbles (tooltips) */
.node-bubble {
  position: absolute;
  bottom: calc(100% + 15px);
  left: 50%;
  transform: translateX(-50%);
  background-color: #121c33; /* Dark premium blue background */
  color: var(--color-white);
  padding: 0.6rem 0.8rem;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 500;
  width: 180px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  pointer-events: none;
  z-index: 20;
  line-height: 1.4;
  border: 1.5px solid var(--color-accent-light); /* Accent color border to make it pop */
  transition: all 0.3s ease;
  white-space: normal;
}

.node-bubble::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 6px;
  border-style: solid;
  border-color: #121c33 transparent transparent transparent;
}

/* Mobile timeline styling */
.mobile-timeline {
  display: none;
  margin-top: 3rem;
  background-color: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 2rem 1.5rem;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.2);
}

@media (max-width: 768px) {
  .node-bubble {
    display: none !important; /* Hide overlapping bubbles on nodes */
  }
  .mobile-timeline {
    display: block; /* Show clean step-by-step timeline list instead */
  }
}

.path-line {
  fill: none;
  stroke: rgba(255, 255, 255, 0.1);
  stroke-width: 2;
  transition: all 0.5s ease;
}
.path-line.active-path {
  stroke: rgba(255, 255, 255, 0.4);
  stroke-width: 2;
}

@keyframes dash {
  to {
    stroke-dashoffset: -1000;
  }
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
  .nav-links a {
    min-height: 44px;
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
  }
  
  /* Mobile Optimizations */
  .container {
    padding: 0 1.25rem;
  }
  
  .card {
    padding: 1.5rem !important; /* Save space on mobile */
  }
  
  .card-grid {
    gap: 1.25rem !important;
  }
  
  .section {
    padding: 3.5rem 0 !important; /* Reduce excessive scrolling */
  }
  
  .hero {
    padding-top: 6rem !important;
    padding-bottom: 3rem !important;
  }
  
  h1 {
    font-size: 2.25rem !important;
    line-height: 1.2 !important;
  }
  
  h2 {
    font-size: 1.75rem !important;
    line-height: 1.25 !important;
  }
  
  h3 {
    font-size: 1.35rem !important;
  }
  
  /* Optimize form padding on mobile */
  .contact-info {
    padding: 1.5rem !important;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }
  
  .card {
    padding: 1.25rem !important;
  }
  
  .section {
    padding: 2.5rem 0 !important;
  }
  
  h1 {
    font-size: 1.95rem !important;
  }
  
  h2 {
    font-size: 1.55rem !important;
  }
}
