/* ========== VARIABLES ========== */
:root {
  --bg-primary: #03040b;
  --bg-secondary: #0a0b16;
  --bg-card: rgba(15, 17, 35, 0.6);
  --bg-glass: rgba(10, 11, 22, 0.4);
  
  --text-main: #f0f0f5;
  --text-muted: #9aa0c0;
  
  --accent-cyan: #00f0ff;
  --accent-blue: #0075ff;
  --accent-purple: #9d00ff;
  --accent-magenta: #ff00ea;
  
  --glow-cyan: rgba(0, 240, 255, 0.4);
  --glow-purple: rgba(157, 0, 255, 0.4);
  
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Outfit', sans-serif;
  
  --transition-fast: 0.2s ease;
  --transition-normal: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  
  --border-radius: 16px;
  --border-glass: 1px solid rgba(255, 255, 255, 0.08);
}

/* ========== RESET & BASE ========== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

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

.accent {
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ========== UTILITIES ========== */
.section {
  padding: 100px 5%;
  position: relative;
}

.section-inner {
  max-width: 1280px;
  margin: 0 auto;
}

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

.section-label {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent-cyan);
  margin-bottom: 15px;
}

.light-label {
  color: var(--accent-magenta);
}

.section-title {
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  margin-bottom: 20px;
}

.section-title.left-align {
  text-align: left;
}

.section-desc {
  color: var(--text-muted);
  font-size: 1.125rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  background: linear-gradient(45deg, var(--accent-blue), var(--accent-purple));
  color: #fff;
  font-weight: 600;
  border-radius: 30px;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(45deg, var(--accent-purple), var(--accent-magenta));
  opacity: 0;
  transition: opacity var(--transition-normal);
  z-index: -1;
}

.btn-primary:hover::before {
  opacity: 1;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(157, 0, 255, 0.3);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  background: transparent;
  color: var(--text-main);
  font-weight: 600;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,0.2);
  transition: var(--transition-normal);
}

.btn-ghost:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  background: rgba(0, 240, 255, 0.05);
}

.light-ghost:hover {
  border-color: var(--accent-magenta);
  color: var(--accent-magenta);
  background: rgba(255, 0, 234, 0.05);
}

/* ========== NAVIGATION ========== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 5%;
  z-index: 100;
  transition: var(--transition-normal);
  background: transparent;
}

.nav.scrolled {
  background: rgba(3, 4, 11, 0.85);
  backdrop-filter: blur(10px);
  padding: 15px 5%;
  border-bottom: var(--border-glass);
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.nav-logo-img {
  width: 40px;
  height: 40px;
}

.nav-logo-text {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: 1px;
}

.nav-links {
  display: flex;
  gap: 30px;
  align-items: center;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: var(--transition-fast);
  position: relative;
}

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

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
}

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

.nav-cta {
  padding: 8px 20px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.1);
  font-size: 0.95rem;
  font-weight: 600;
  transition: var(--transition-normal);
  border: 1px solid rgba(255,255,255,0.1);
}

.nav-cta:hover {
  background: var(--text-main);
  color: var(--bg-primary);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 30px;
  height: 20px;
  position: relative;
  z-index: 101;
}

.hamburger {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--text-main);
  transition: var(--transition-normal);
}

.hamburger:nth-child(1) { top: 0; }
.hamburger:nth-child(2) { top: 9px; }
.hamburger:nth-child(3) { top: 18px; }

/* ========== HERO ========== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 5%;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-bg-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(to bottom, rgba(3, 4, 11, 0.05) 0%, rgba(3, 4, 11, 0.35) 50%, rgba(3, 4, 11, 0.7) 85%, var(--bg-primary) 100%);
}

.hero-canvas {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: 1;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 900px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  font-size: 0.85rem;
  margin-bottom: 30px;
  backdrop-filter: blur(5px);
  animation: fadeUp 1s ease 0.2s both;
}

.badge-dot {
  width: 8px; height: 8px;
  background: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-cyan);
  animation: pulse 2s infinite;
}

.hero-title {
  font-size: clamp(3rem, 6vw, 5.5rem);
  display: flex;
  flex-direction: column;
  margin-bottom: 25px;
}

.hero-title span {
  display: block;
}

.hero-title-line {
  animation: fadeUp 1s ease 0.4s both;
}

.hero-title-accent {
  background: linear-gradient(to right, var(--accent-cyan), var(--accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: fadeUp 1s ease 0.6s both;
}

.hero-sub {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 40px;
  animation: fadeUp 1s ease 0.8s both;
}

.hero-sub strong {
  color: var(--text-main);
}

.hero-ctas {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 60px;
  animation: fadeUp 1s ease 1s both;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  animation: fadeUp 1s ease 1.2s both;
}

.stat-card {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.stat-num {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero-scroll {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 2;
  animation: fadeUp 1s ease 1.5s both;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--accent-cyan), transparent);
  animation: scrollDown 2s infinite;
}

.scroll-text {
  font-size: 0.75rem;
  letter-spacing: 2px;
  color: var(--text-muted);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

/* ========== SERVICES GRID ========== */
.services-section {
  background: linear-gradient(to bottom, var(--bg-primary), var(--bg-secondary));
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.service-card {
  background: var(--bg-card);
  border: var(--border-glass);
  border-radius: var(--border-radius);
  overflow: hidden;
  position: relative;
  transition: var(--transition-normal);
  backdrop-filter: blur(10px);
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255,255,255,0.2);
}

.service-card-glow {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: radial-gradient(circle at 50% 0%, rgba(0, 240, 255, 0.1) 0%, transparent 60%);
  opacity: 0;
  transition: var(--transition-normal);
  pointer-events: none;
}

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

.service-img-wrap {
  height: 250px;
  position: relative;
  overflow: hidden;
}

.service-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.service-card:hover .service-img {
  transform: scale(1.05);
}

.service-img-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(to bottom, transparent 50%, var(--bg-card) 100%);
  display: flex;
  align-items: flex-end;
  padding: 20px;
}

.service-icon {
  width: 50px;
  height: 50px;
  background: rgba(3, 4, 11, 0.8);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
  backdrop-filter: blur(5px);
}

.service-body {
  padding: 30px;
}

.service-tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--accent-purple);
  font-weight: 600;
  margin-bottom: 10px;
  display: block;
}

.service-tag.featured-tag {
  color: var(--accent-magenta);
}

.service-title {
  font-size: 1.5rem;
  margin-bottom: 15px;
}

.service-desc {
  color: var(--text-muted);
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.service-features {
  border-top: 1px solid rgba(255,255,255,0.05);
  padding-top: 20px;
}

.service-features li {
  font-size: 0.9rem;
  color: #ccc;
  margin-bottom: 8px;
  position: relative;
  padding-left: 20px;
}

.service-features li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-cyan);
}

/* ========== PARALLAX BREAK ========== */
.parallax-break {
  height: 60vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.parallax-img {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 130%;
  object-fit: cover;
  z-index: 0;
  transform: translateY(0);
  will-change: transform;
}

.parallax-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(3,4,11,0.6);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.parallax-text {
  text-align: center;
  max-width: 800px;
  padding: 0 5%;
}

.parallax-quote {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 500;
  margin-bottom: 20px;
  line-height: 1.3;
}

.parallax-source {
  color: var(--accent-cyan);
  font-size: 1.1rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ========== TECHNOLOGY SECTION ========== */
.tech-section {
  background: var(--bg-secondary);
}

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

.tech-visual {
  position: relative;
  border-radius: var(--border-radius);
  overflow: hidden;
  border: var(--border-glass);
}

.tech-main-img {
  width: 100%;
  display: block;
}

/* Simple Orbit Animation */
.orbit-ring {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  border: 1px dashed rgba(255,255,255,0.2);
  border-radius: 50%;
}
.orbit-1 { width: 60%; height: 60%; animation: spin 20s linear infinite; }
.orbit-2 { width: 80%; height: 80%; animation: spin 30s linear infinite reverse; }

.orbit-node {
  position: absolute;
  background: rgba(3,4,11,0.8);
  border: 1px solid var(--accent-cyan);
  color: var(--accent-cyan);
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: bold;
}
.node-llm { top: -10px; left: 50%; transform: translateX(-50%); }
.node-cv { bottom: -10px; left: 50%; transform: translateX(-50%); }
.node-geo { top: 50%; left: -10px; transform: translateY(-50%); }
.node-ar { top: 50%; right: -10px; transform: translateY(-50%); }

.tech-pillars {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.tech-pillar {
  display: flex;
  gap: 20px;
  background: var(--bg-card);
  padding: 25px;
  border-radius: var(--border-radius);
  border: var(--border-glass);
}

.pillar-icon {
  flex-shrink: 0;
  width: 50px; height: 50px;
  background: rgba(255,255,255,0.05);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent-purple);
}

.pillar-content h3 {
  font-size: 1.25rem;
  margin-bottom: 10px;
}

.pillar-content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 15px;
}

.skill-bars {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.skill-bar {
  position: relative;
  height: 4px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
}

.skill-bar::before {
  content: attr(data-label);
  position: absolute;
  top: -18px;
  left: 0;
  font-size: 0.75rem;
  color: #ccc;
}

.skill-bar::after {
  content: '';
  position: absolute;
  top: 0; left: 0; height: 100%;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-blue));
  border-radius: 2px;
  width: 0; /* Animated in JS */
  transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ========== MARKET INFOGRAPHIC ========== */
.market-section {
  background: var(--bg-primary);
}

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

.market-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.market-ring-outer {
  position: relative;
  width: 300px; height: 300px;
}

.market-svg {
  width: 100%; height: 100%;
  transform: rotate(-90deg);
}

.ring-track {
  fill: none;
  stroke: rgba(255,255,255,0.05);
  stroke-width: 15;
}

.ring-fill {
  fill: none;
  stroke-width: 15;
  stroke-linecap: round;
  transition: stroke-dashoffset 2s ease-out;
}

.ring-1 { stroke: var(--accent-cyan); }
.ring-2 { stroke: var(--accent-purple); }
.ring-3 { stroke: var(--accent-magenta); }

.market-center {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}

.market-center-num {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(to right, var(--accent-cyan), var(--accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.market-center-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.market-legend {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
}

.legend-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
}
.dot-1 { background: var(--accent-cyan); }
.dot-2 { background: var(--accent-purple); }
.dot-3 { background: var(--accent-magenta); }

.market-infographic-tree {
  position: relative;
  width: 100%;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tree-lines {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

.tree-path {
  stroke-dasharray: 500;
  stroke-dashoffset: 500;
  transition: stroke-dashoffset 2s ease-out;
}

.tree-center-dot {
  box-shadow: 0 0 20px var(--accent-cyan);
  animation: pulse 2s infinite;
}

.tree-node {
  position: absolute;
  width: 280px;
  background: var(--bg-card);
  padding: 20px;
  border-radius: var(--border-radius);
  border: var(--border-glass);
  display: flex;
  gap: 15px;
  z-index: 1;
  transition: var(--transition-normal);
  backdrop-filter: blur(10px);
}

.tree-node:hover {
  transform: translateY(-5px) scale(1.02);
  border-color: var(--accent-cyan);
  box-shadow: 0 10px 30px rgba(0, 240, 255, 0.1);
}

.node-tl { top: 10%; left: 0; }
.node-tr { top: 10%; right: 0; }
.node-bl { bottom: 10%; left: 0; }
.node-br { bottom: 10%; right: 0; }

.node-icon {
  font-size: 1.8rem;
  background: rgba(255,255,255,0.05);
  width: 50px; height: 50px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  flex-shrink: 0;
}

.node-content h3 {
  font-size: 1.05rem;
  margin-bottom: 5px;
  color: var(--text-main);
}

.node-content p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ========== ABOUT ========== */
.about-section {
  background: var(--bg-secondary);
}

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

.about-text {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.about-text strong {
  color: var(--text-main);
}

.about-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.badge {
  padding: 6px 14px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  font-size: 0.85rem;
  color: var(--accent-cyan);
}

/* Hex Grid Animation */
.hex-grid {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  max-width: 500px;
  margin: 0 auto;
}

.hex-cell {
  position: absolute;
  width: 80px; height: 90px;
  background: rgba(3,4,11,0.8);
  border: 1px solid var(--accent-purple);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display: flex; align-items: center; justify-content: center;
  font-weight: bold;
  font-size: 0.9rem;
  transition: var(--transition-normal);
}

.hex-cell:hover {
  background: rgba(157, 0, 255, 0.2);
  transform: scale(1.1);
}

.hex-center {
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  background: var(--accent-purple);
  color: #fff;
  border: none;
  z-index: 2;
}

.hex-center:hover {
  transform: translate(-50%, -50%) scale(1.1);
  background: var(--accent-purple);
}

/* Positions for surrounding hexes */
#hex-cpo { top: 20%; left: 50%; transform: translateX(-50%); }
#hex-cv2 { top: 35%; right: 20%; }
#hex-ar { bottom: 35%; right: 20%; }
#hex-geo2 { bottom: 20%; left: 50%; transform: translateX(-50%); }
#hex-llm { bottom: 35%; left: 20%; }
#hex-xr { top: 35%; left: 20%; }

.hex-connector {
  position: absolute;
  top: 50%; left: 50%;
  width: 2px; height: 30%;
  background: linear-gradient(to top, var(--accent-purple), transparent);
  transform-origin: bottom center;
  z-index: 1;
}

#hc1 { transform: translate(-50%, -100%) rotate(0deg); }
#hc2 { transform: translate(-50%, -100%) rotate(60deg); }
#hc3 { transform: translate(-50%, -100%) rotate(120deg); }
#hc4 { transform: translate(-50%, -100%) rotate(180deg); }
#hc5 { transform: translate(-50%, -100%) rotate(240deg); }
#hc6 { transform: translate(-50%, -100%) rotate(300deg); }

/* ========== CONTACT ========== */
.contact-section {
  text-align: center;
  padding: 150px 5%;
}

.contact-bg {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
}

.contact-bg-img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.contact-bg-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(to top, var(--bg-primary) 0%, rgba(3,4,11,0.7) 100%);
}

.contact-inner {
  position: relative;
  z-index: 2;
}

.light-title {
  font-size: clamp(3rem, 5vw, 4.5rem);
}

.contact-ctas {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-top: 40px;
}

/* ========== FOOTER ========== */
.footer {
  background: var(--bg-primary);
  padding: 60px 5% 30px;
  border-top: var(--border-glass);
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.footer-logo {
  width: 30px; height: 30px;
}

.footer-name {
  font-family: var(--font-heading);
  font-weight: 800;
  letter-spacing: 1px;
}

.footer-tagline {
  color: var(--text-muted);
  margin-bottom: 30px;
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 40px;
}

.footer-links a {
  color: #ccc;
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}

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

.footer-copy {
  color: rgba(255,255,255,0.3);
  font-size: 0.8rem;
}

/* ========== ANIMATIONS ========== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 240, 255, 0.7); }
  70% { box-shadow: 0 0 0 10px rgba(0, 240, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 240, 255, 0); }
}

@keyframes scrollDown {
  0% { transform: translateY(-100%); opacity: 0; }
  50% { opacity: 1; }
  100% { transform: translateY(100%); opacity: 0; }
}

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

/* Utility class for scroll animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
  .services-grid { grid-template-columns: 1fr; }
  .tech-layout, .market-infographic, .about-layout { grid-template-columns: 1fr; gap: 40px; }
  .tech-visual { order: -1; }
  .market-visual { order: -1; }
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0; right: -100%;
    width: 250px; height: 100vh;
    background: var(--bg-secondary);
    flex-direction: column;
    justify-content: center;
    transition: var(--transition-normal);
    border-left: var(--border-glass);
  }
  .nav-links.active { right: 0; }
  .nav-toggle { display: block; }
  .nav-toggle.active .hamburger:nth-child(1) { transform: rotate(45deg); top: 9px; }
  .nav-toggle.active .hamburger:nth-child(2) { opacity: 0; }
  .nav-toggle.active .hamburger:nth-child(3) { transform: rotate(-45deg); top: 9px; }
  
  .hero-ctas, .contact-ctas { flex-direction: column; }
  .hero-stats { flex-direction: column; gap: 20px; }
  .market-infographic-tree {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 0;
  }
  .tree-node {
    position: relative;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    width: 100%;
  }
  .tree-lines { display: none; }
}

/* ========== LIVE AVATAR WIDGET ========== */
.avatar-widget-container {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

/* Floating Action Button (FAB) */
.avatar-fab {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  box-shadow: 0 8px 30px rgba(0, 240, 255, 0.4);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
  z-index: 10;
  padding: 0;
  overflow: hidden;
}

.avatar-fab-profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid var(--accent-cyan);
  z-index: 2;
  transition: transform 0.3s ease;
}

.avatar-fab:hover .avatar-fab-profile-img {
  transform: scale(1.08);
}

.avatar-fab:hover {
  transform: scale(1.08) translateY(-2px);
  box-shadow: 0 12px 35px rgba(0, 240, 255, 0.6);
}

.avatar-fab:active {
  transform: scale(0.95);
}

.avatar-fab-glow {
  position: absolute;
  top: -4px; left: -4px; right: -4px; bottom: -4px;
  border-radius: 50%;
  border: 2px solid var(--accent-cyan);
  opacity: 0.5;
  animation: fabPulse 2.5s infinite;
  pointer-events: none;
}

.avatar-fab-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.avatar-fab:hover .avatar-fab-icon {
  transform: rotate(15deg);
}

.avatar-tooltip {
  position: absolute;
  right: 75px;
  top: 50%;
  transform: translateY(-50%) translateX(10px);
  background: rgba(10, 11, 22, 0.85);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 16px;
  border-radius: 20px;
  color: var(--text-main);
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.avatar-fab:hover .avatar-tooltip {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

/* Expanded Card State */
.avatar-card {
  width: 340px;
  height: 460px;
  border-radius: 20px;
  background: rgba(10, 11, 22, 0.7);
  backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: absolute;
  bottom: 0;
  right: 0;
  transform: translateY(20px) scale(0.95);
  opacity: 0;
  pointer-events: none;
  transform-origin: bottom right;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 5;
}

.avatar-card.active {
  transform: translateY(0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.avatar-card-header {
  padding: 15px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(10, 11, 22, 0.4);
}

.avatar-status-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.avatar-status-dot.offline {
  background: #64748b;
}

.avatar-status-dot.connecting {
  background: #eab308;
  box-shadow: 0 0 8px #eab308;
  animation: pulse 1.5s infinite;
}

.avatar-status-dot.online {
  background: #22c55e;
  box-shadow: 0 0 10px #22c55e;
  animation: pulse 1.5s infinite;
}

.avatar-status-text {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--text-main);
}

.avatar-close-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 50%;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.avatar-close-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

/* Video Frame with Rounded Corners */
.avatar-video-container {
  flex: 1;
  position: relative;
  background: #03040b;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#persona-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  background: #03040b;
}

/* Overlays inside video container */
.avatar-overlay-screen {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(135deg, rgba(6, 8, 20, 0.95), rgba(3, 4, 11, 0.98));
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  text-align: center;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.avatar-overlay-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#avatar-start-screen {
  background: linear-gradient(to bottom, rgba(3, 4, 11, 0.15) 0%, rgba(3, 4, 11, 0.5) 50%, rgba(3, 4, 11, 0.9) 100%);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

#avatar-loading-screen {
  background: rgba(3, 4, 11, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.avatar-start-glow {
  position: absolute;
  width: 180px; height: 180px;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.15) 0%, transparent 70%);
  top: 15%;
  pointer-events: none;
}

.avatar-overlay-screen h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  margin-bottom: 12px;
  background: linear-gradient(to right, var(--accent-cyan), var(--accent-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.avatar-overlay-screen p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 25px;
  max-width: 250px;
}

.avatar-start-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 26px;
  background: linear-gradient(45deg, var(--accent-blue), var(--accent-purple));
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 30px;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(157, 0, 255, 0.35);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.avatar-start-btn::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(45deg, var(--accent-purple), var(--accent-magenta));
  opacity: 0;
  transition: opacity var(--transition-normal);
  z-index: 1;
}

.avatar-start-btn:hover::before {
  opacity: 1;
}

.avatar-start-btn span {
  position: relative;
  z-index: 2;
}

.avatar-start-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(157, 0, 255, 0.5);
}

.avatar-disclosure {
  font-size: 0.7rem;
  color: #64748b;
  margin-top: 15px;
}

/* Spinner */
.avatar-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(255, 255, 255, 0.05);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-bottom: 18px;
}

#avatar-loading-text {
  font-size: 0.85rem;
  color: var(--text-main);
  letter-spacing: 0.5px;
}

/* Footer Controls */
.avatar-card-footer {
  padding: 15px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(5, 6, 15, 0.6);
}

.avatar-control-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.avatar-control-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

.avatar-control-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.avatar-control-btn.muted {
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.25);
  color: #ef4444;
}

.avatar-control-btn.muted:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.18);
  border-color: rgba(239, 68, 68, 0.4);
}

.avatar-control-btn.stop-btn:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.hidden {
  display: none !important;
}

/* Animations */
@keyframes fabPulse {
  0% {
    transform: scale(1);
    opacity: 0.5;
  }
  70% {
    transform: scale(1.2);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 0;
  }
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Mobile Responsiveness for Widget */
@media (max-width: 480px) {
  .avatar-widget-container {
    bottom: 15px;
    right: 15px;
  }
  
  .avatar-card {
    width: 25vw;
    height: 38vw;
    min-width: 150px;
    min-height: 220px;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  }
  
  .avatar-card-header {
    padding: 8px 12px;
  }
  
  .avatar-status-text {
    font-size: 0.65rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 80px;
  }
  
  .avatar-status-dot {
    width: 6px;
    height: 6px;
  }
  
  .avatar-close-btn {
    padding: 2px;
  }
  
  .avatar-close-btn svg {
    width: 12px;
    height: 12px;
  }
  
  .avatar-card-footer {
    padding: 8px 12px;
    gap: 8px;
  }
  
  .avatar-control-btn {
    width: 32px;
    height: 32px;
    padding: 6px;
  }
  
  .avatar-control-btn svg {
    width: 14px;
    height: 14px;
  }
  
  /* Scale loading and start screens for small container */
  .avatar-overlay-screen {
    padding: 12px;
  }
  
  .avatar-overlay-screen h3 {
    font-size: 0.8rem !important;
    margin-bottom: 4px !important;
    line-height: 1.2;
  }
  
  .avatar-overlay-screen p {
    font-size: 0.65rem !important;
    margin-bottom: 10px !important;
    line-height: 1.3;
    max-width: 120px !important;
  }
  
  .avatar-start-btn {
    padding: 6px 12px !important;
    font-size: 0.65rem !important;
  }
  
  .avatar-disclosure {
    font-size: 0.55rem !important;
    max-width: 110px !important;
    margin-top: 4px;
  }

  .avatar-spinner {
    width: 24px;
    height: 24px;
    border-width: 2px;
  }
  
  .avatar-tooltip {
    display: none; /* Hide hover tooltip on touch devices */
  }
}

/* State B: Portrait Preview Card */
.avatar-portrait-preview {
  width: 125px;
  height: 175px;
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  border: 1px solid rgba(0, 240, 255, 0.25);
  box-shadow: 0 10px 30px rgba(0, 240, 255, 0.15), 0 0 15px rgba(0, 240, 255, 0.08);
  background: rgba(10, 11, 22, 0.6);
  backdrop-filter: blur(15px);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
  transform-origin: bottom right;
  z-index: 8;
}

.avatar-portrait-preview.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: scale(0.8) translateY(20px);
}

.avatar-portrait-preview:hover {
  transform: scale(1.06) translateY(-4px);
  box-shadow: 0 15px 35px rgba(0, 240, 255, 0.3), 0 0 25px rgba(0, 240, 255, 0.12);
  border-color: var(--accent-cyan);
}

.avatar-portrait-minimize {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(3, 4, 11, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 12;
  transition: all 0.2s ease;
}

.avatar-portrait-minimize:hover {
  background: rgba(239, 68, 68, 0.9);
  color: #fff;
  border-color: transparent;
}

.avatar-portrait-img-wrap {
  width: 100%;
  height: 100%;
  position: relative;
}

.avatar-portrait-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.avatar-portrait-preview:hover .avatar-portrait-img {
  transform: scale(1.04);
}

.avatar-portrait-overlay {
  position: absolute;
  bottom: 0; left: 0; width: 100%;
  padding: 12px 10px;
  background: linear-gradient(to top, rgba(3, 4, 11, 0.95) 0%, rgba(3, 4, 11, 0.4) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  gap: 4px;
  pointer-events: none;
}

.avatar-portrait-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--accent-cyan);
  letter-spacing: 0.5px;
}

.avatar-portrait-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
  animation: pulse 1.5s infinite;
}

.avatar-portrait-title {
  font-size: 0.75rem;
  font-weight: 600;
  color: #fff;
  line-height: 1.2;
}

/* Glassmorphic retry button for connection / error screens */
.avatar-retry-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  background: linear-gradient(45deg, var(--accent-blue), var(--accent-purple));
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 20px;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 15px rgba(157, 0, 255, 0.25);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  margin-top: 15px;
  position: relative;
  z-index: 10;
}

.avatar-retry-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(157, 0, 255, 0.4);
}

.avatar-retry-btn:active {
  transform: scale(0.97);
}

.avatar-retry-btn.hidden {
  display: none !important;
}

.avatar-help-icon {
  animation: floatWarning 3s ease-in-out infinite;
}

@keyframes floatWarning {
  0% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
  100% { transform: translateY(0); }
}

/* Beautiful live avatar image placeholder inside video container */
.avatar-video-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2; /* Shows above video tag, below connection overlays */
  opacity: 1;
  visibility: visible;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.6s step-end;
}

.avatar-video-placeholder.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.6s step-end;
}
