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

:root {
  --bg: #050a14;
  --surface: rgba(8, 18, 35, 0.85);
  --accent: #0ef;
  --accent-dim: rgba(0, 238, 255, 0.6);
  --amber: #f0a030;
  --magenta: #ff2d75;
  --text: #c8d6e5;
  --text-muted: #5a7089;
  --border-glow: rgba(0, 238, 255, 0.15);
  --border-glow-hover: rgba(0, 238, 255, 0.35);
  --font-mono: 'Space Mono', 'Courier New', monospace;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --radius-card: 2px;
  --radius-pill: 999px;
  --shadow-card: 0 0 15px rgba(0, 240, 255, 0.05), inset 0 1px 0 rgba(0, 240, 255, 0.1);
  --shadow-hover: 0 0 25px rgba(0, 240, 255, 0.12), inset 0 1px 0 rgba(0, 240, 255, 0.2);
  --nav-bg: rgba(5, 10, 20, 0.9);
}

html {
  scroll-behavior: smooth;
}

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

/* ===== Scan-Line Overlay ===== */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 240, 255, 0.015) 0px,
    rgba(0, 240, 255, 0.015) 1px,
    transparent 1px,
    transparent 4px
  );
  pointer-events: none;
  z-index: 9999;
}

/* ===== Perspective Grid Floor ===== */
.grid-floor {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40vh;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(0, 238, 255, 0.04) 0px,
      rgba(0, 238, 255, 0.04) 1px,
      transparent 1px,
      transparent 60px
    ),
    repeating-linear-gradient(
      0deg,
      rgba(0, 238, 255, 0.04) 0px,
      rgba(0, 238, 255, 0.04) 1px,
      transparent 1px,
      transparent 60px
    );
  transform: perspective(500px) rotateX(60deg);
  transform-origin: bottom center;
  mask-image: linear-gradient(to bottom, transparent 0%, black 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 100%);
  pointer-events: none;
  z-index: -1;
}

/* ===== Skip to content ===== */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  background: var(--accent);
  color: var(--bg);
  padding: 8px 16px;
  border-radius: 0 0 8px 8px;
  font-weight: 600;
  font-size: 0.875rem;
  z-index: 1000;
  text-decoration: none;
  transition: top 200ms;
}

.skip-link:focus {
  top: 0;
}

/* ===== Font Utilities ===== */
.font-mono {
  font-family: var(--font-mono);
}

.hud-label {
  text-transform: uppercase;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--accent-dim);
  font-family: var(--font-mono);
}

.section-hud-label {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.section-hud-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--accent-dim), transparent);
}

/* ===== Navigation ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(0, 238, 255, 0.1);
  transform: translateY(-100%);
  transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1);
}

.nav.visible {
  transform: translateY(0);
}

.nav-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-logo {
  font-weight: 800;
  font-size: 1.1rem;
  font-family: var(--font-mono);
  color: var(--accent);
  text-decoration: none;
  flex-shrink: 0;
}

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

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  transition: color 150ms, background 150ms;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent);
  background: rgba(0, 238, 255, 0.08);
}

.nav-sep {
  opacity: 0.4;
  color: var(--accent-dim);
  font-size: 0.5rem;
  line-height: 1;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  display: inline-block;
  animation: status-pulse 2s ease-in-out infinite;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.nav-cta {
  font-size: 0.75rem;
  font-weight: 600;
  font-family: var(--font-mono);
  color: var(--accent);
  background: transparent;
  border: 1px solid var(--accent);
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background 150ms, box-shadow 150ms;
}

.nav-cta:hover {
  background: rgba(0, 238, 255, 0.1);
  box-shadow: 0 0 16px rgba(0, 238, 255, 0.2);
}

/* ===== Starfield Background ===== */
.starfield {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

#starfield-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.starfield.gl-active .stars {
  display: none;
}

.stars {
  position: absolute;
  top: 0;
  left: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.8);
  will-change: transform;
  opacity: 1;
}

.stars-sm {
  animation: star-drift 120s linear infinite, star-blink-slow 6s ease-in-out infinite;
}

.stars-md {
  animation: star-drift 80s linear infinite, star-blink-med 4s ease-in-out infinite 1s;
}

.stars-lg {
  animation: star-drift 60s linear infinite, star-blink-fast 3s ease-in-out infinite 0.5s;
}

@keyframes star-drift {
  from { transform: translateY(0); }
  to   { transform: translateY(-2000px); }
}

@keyframes star-blink-slow {
  0%, 100% { opacity: 0.3; }
  30%      { opacity: 0.9; }
  60%      { opacity: 0.5; }
  80%      { opacity: 1; }
}

@keyframes star-blink-med {
  0%, 100% { opacity: 0.4; }
  25%      { opacity: 1; }
  50%      { opacity: 0.6; }
  75%      { opacity: 0.9; }
}

@keyframes star-blink-fast {
  0%, 100% { opacity: 0.5; }
  40%      { opacity: 1; }
  70%      { opacity: 0.3; }
}

/* Dynamic comets */
@keyframes comet-fly {
  0%   { opacity: 0; transform: translate(0, 0) scale(1); }
  10%  { opacity: 1; }
  70%  { opacity: 0.8; }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(0.3); }
}

/* Shooting stars */
.starfield::before,
.starfield::after {
  content: '';
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 6px 2px rgba(255, 255, 255, 0.3);
  opacity: 0;
  will-change: transform, opacity;
}

.starfield::before {
  top: 15%;
  left: 70%;
  animation: shooting-star 12s ease-in-out infinite 4s;
}

.starfield::after {
  top: 40%;
  left: 30%;
  animation: shooting-star 15s ease-in-out infinite 9s;
}

@keyframes shooting-star {
  0%, 90%, 100% { opacity: 0; transform: translate(0, 0) scale(1); }
  92% { opacity: 1; transform: translate(-80px, 80px) scale(1); }
  95% { opacity: 0; transform: translate(-200px, 200px) scale(0.5); }
}

/* Nebula clouds */
.nebula {
  position: absolute;
  border-radius: 50%;
  will-change: transform;
}

.nebula-1 {
  width: 600px;
  height: 600px;
  top: -200px;
  left: -150px;
  background: radial-gradient(circle, rgba(0, 238, 255, 0.04), transparent 70%);
  animation: nebula-drift-1 30s ease-in-out infinite;
}

.nebula-2 {
  width: 500px;
  height: 500px;
  bottom: -100px;
  right: -180px;
  background: radial-gradient(circle, rgba(240, 160, 48, 0.03), transparent 70%);
  animation: nebula-drift-2 35s ease-in-out infinite;
}

@keyframes nebula-drift-1 {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(40px, 30px); }
}

@keyframes nebula-drift-2 {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(-30px, -20px); }
}

/* ===== Container ===== */
.container {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Hero Section ===== */
.hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px 48px;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  will-change: transform, opacity;
}

/* Hero Panel (HUD frame) */
.hero-panel {
  max-width: 580px;
  padding: 48px;
  position: relative;
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  background: linear-gradient(135deg, rgba(0, 238, 255, 0.03), rgba(0, 238, 255, 0.01));
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  background-image:
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim));
  background-size:
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px;
  background-position:
    top left, top left,
    top right, top right,
    bottom left, bottom left,
    bottom right, bottom right;
  background-repeat: no-repeat;
  transition: background-size 0.3s ease, box-shadow 0.3s ease;
}

.hero-panel:hover {
  background-size:
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px;
  box-shadow: var(--shadow-hover);
}

/* Crew label */
.crew-label {
  position: absolute;
  top: 12px;
  left: 16px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

/* Avatar */
.avatar-wrap {
  display: flex;
  justify-content: center;
}

.avatar-ring {
  width: 130px;
  height: 130px;
  border-radius: 50%;
  padding: 4px;
  background: transparent;
  position: relative;
}

.avatar-hud-ring {
  position: relative;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-hud-ring .avatar-ring {
  width: 120px;
  height: 120px;
}

.ring-outer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: ring-spin 4s linear infinite;
}

.ring-outer circle {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
}

.ring-inner {
  position: absolute;
  inset: 5px;
  width: calc(100% - 10px);
  height: calc(100% - 10px);
  animation: ring-spin 6s linear infinite reverse;
}

.ring-inner circle {
  fill: none;
  stroke: var(--amber);
  stroke-width: 1;
}

.avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  background: var(--surface);
}

.avatar-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--amber));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 800;
  color: white;
  letter-spacing: -1px;
}

/* Hero name */
.hero-name {
  font-size: clamp(2.8rem, 8vw, 5rem);
  font-weight: 800;
  letter-spacing: -2px;
  line-height: 1;
  background: linear-gradient(135deg, var(--accent) 0%, #ffffff 80%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Badge row */
.badge-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.badge {
  background: transparent;
  border: 1px solid var(--border-glow);
  color: var(--accent);
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-family: var(--font-mono);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.badge-dot {
  color: var(--text-muted);
  font-size: 1.2rem;
}

/* Tagline */
.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--text-muted);
  max-width: 440px;
  font-weight: 500;
}

/* Social links */
.social-links {
  display: flex;
  gap: 12px;
  margin-top: 4px;
}

.social-link {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--border-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.social-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: scale(1.15) translateY(-2px);
  box-shadow: 0 0 20px rgba(0, 238, 255, 0.3);
}

/* Hero CTA */
.hero-cta {
  margin-top: 8px;
}

.btn-primary {
  display: inline-block;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  padding: 14px 32px;
  border: 1px solid var(--accent);
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: all 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-primary:hover {
  background: rgba(0, 238, 255, 0.1);
  box-shadow: 0 0 24px rgba(0, 238, 255, 0.3);
  transform: scale(1.04) translateY(-2px);
}

/* ===== Hero Animations (on load) ===== */
.animate-in {
  opacity: 0;
  transform: translateY(24px);
  animation: fadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: var(--delay, 0s);
}

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

/* ===== Sections ===== */
.section {
  padding: 48px 0;
}

.section + .section {
  padding-top: 0;
}

.section-title {
  font-size: clamp(1.6rem, 4vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--text);
  margin-bottom: 32px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  display: block;
  width: 0;
  height: 2px;
  background: var(--accent);
  margin-top: 8px;
  transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.3s;
}

.reveal.visible .section-title::after {
  width: 40px;
}

/* ===== Scroll Reveal (Glitch Reveal) ===== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Staggered children within revealed sections */
.reveal.visible .featured-grid > *,
.reveal.visible .timeline > .timeline-entry,
.reveal.visible .talks-grid > *,
.reveal.visible .testimonials-grid > *,
.reveal.visible .research-grid > *,
.reveal.visible .blog-list > *,
.reveal.visible .projects-grid > *,
.reveal.visible .stat-chips > * {
  opacity: 0;
  transform: translateY(16px);
  animation: stagger-in 0.55s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--stagger, 0) * 70ms);
}

@keyframes stagger-in {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Scan Sweep Effect ===== */
.scan-sweep {
  position: relative;
}

.scan-sweep::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(0, 238, 255, 0.06) 50%, transparent 100%);
  transform: translateX(-100%);
  z-index: 1;
  pointer-events: none;
}

.scan-sweep.active::before {
  animation: scan-sweep 1.5s ease-in-out forwards;
}

@keyframes scan-sweep {
  from { transform: translateX(-100%); }
  to { transform: translateX(100%); }
}

/* ===== Holographic Glass Card Base ===== */
.about-card,
.timeline-card,
.featured-card,
.talk-card,
.project-card,
.testimonial-card,
.research-card,
.blog-pill {
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  background: linear-gradient(135deg, rgba(0, 238, 255, 0.03), rgba(0, 238, 255, 0.01));
  border: 1px solid var(--border-glow);
  box-shadow: var(--shadow-card);
  border-radius: var(--radius-card);
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.about-card:hover,
.timeline-card:hover,
.featured-card:hover,
.talk-card:hover,
.project-card:not(.project-card--placeholder):hover,
.testimonial-card:hover,
.research-card:hover,
.blog-pill:hover {
  border-color: var(--border-glow-hover);
  box-shadow: var(--shadow-hover);
}

/* ===== Holo Panel (Corner Brackets) ===== */
.holo-panel {
  background-image:
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim)),
    linear-gradient(var(--accent-dim), var(--accent-dim));
  background-size:
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px,
    16px 1px,
    1px 16px;
  background-position:
    top left, top left,
    top right, top right,
    bottom left, bottom left,
    bottom right, bottom right;
  background-repeat: no-repeat;
  transition: background-size 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.holo-panel:hover {
  background-size:
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px,
    24px 1px,
    1px 24px;
}

/* ===== About ===== */
.about-card {
  padding: 36px 40px;
}

.about-text {
  font-size: 1.05rem;
  color: var(--text);
  line-height: 1.75;
  margin-bottom: 16px;
}

.about-text:last-of-type {
  margin-bottom: 0;
}

.inline-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1.5px solid transparent;
  transition: border-color 150ms;
}

.inline-link:hover {
  border-color: var(--accent);
}

/* Stat chips */
.stat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.stat-chip {
  background: transparent;
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  padding: 10px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 100px;
}

/* Stat Ring */
.stat-ring-wrap {
  position: relative;
  width: 48px;
  height: 48px;
}

.stat-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.stat-ring-bg {
  stroke: var(--border-glow);
  stroke-width: 2;
  fill: none;
}

.stat-ring-fill {
  stroke: var(--accent);
  stroke-width: 2;
  fill: none;
  transition: stroke-dashoffset 1s ease-out;
}

.stat-num {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-mono);
}

.stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 2px;
  font-family: var(--font-mono);
}

/* ===== Skills ===== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.skill-group {
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  background: linear-gradient(135deg, rgba(0, 238, 255, 0.03), rgba(0, 238, 255, 0.01));
  border-radius: var(--radius-card);
  padding: 22px 24px;
  border: 1px solid var(--border-glow);
  box-shadow: var(--shadow-card);
}

.skill-group-title {
  font-size: 0.75rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-tag {
  background: transparent;
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  padding: 5px 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ===== Experience Timeline ===== */
.timeline {
  position: relative;
  padding-left: 28px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 4px;
  bottom: 4px;
  width: 1px;
  background: var(--accent);
  opacity: 0.2;
}

.timeline-entry {
  position: relative;
  margin-bottom: 20px;
}

.timeline-entry:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -24px;
  top: 20px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
}

.timeline-card {
  position: relative;
  padding: 20px 24px;
}

.timeline-card:hover {
  transform: translateX(4px);
}

.log-id {
  position: absolute;
  top: 8px;
  right: 12px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--amber);
  opacity: 0.6;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.timeline-company-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.timeline-logo-wrap {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-card);
  overflow: hidden;
  flex-shrink: 0;
  background: #fff;
  border: 1px solid var(--border-glow);
  display: flex;
  align-items: center;
  justify-content: center;
}

.timeline-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.timeline-logo-fb {
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.5px;
  font-family: var(--font-mono);
}

.timeline-company {
  display: block;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}

a.timeline-company-link {
  text-decoration: none;
  color: var(--text);
  transition: color 150ms;
}

a.timeline-company-link:hover {
  color: var(--accent);
}

.timeline-industry {
  display: block;
  font-size: 0.7rem;
  color: var(--accent);
  font-weight: 600;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 1px;
}

.timeline-period {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  flex-shrink: 0;
  font-family: var(--font-mono);
}

.timeline-role {
  font-size: 0.875rem;
  color: var(--accent);
  font-weight: 600;
  margin: 10px 0 8px;
}

.timeline-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.timeline-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  font-family: var(--font-mono);
}

.timeline-link:hover {
  text-decoration: underline;
}

/* ===== Featured Work ===== */
.featured-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.featured-card {
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
}

.featured-card:hover {
  transform: scale(1.02) translateY(-2px);
}

.featured-card--wide {
  grid-column: 1 / -1;
}

.featured-card--navitaire:hover {
  transform: none;
}

.featured-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.featured-name {
  display: block;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}

.featured-at {
  display: block;
  font-size: 0.72rem;
  color: var(--accent);
  font-family: var(--font-mono);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 1px;
}

.featured-external {
  margin-left: auto;
  font-size: 1.1rem;
  color: var(--accent);
  text-decoration: none;
  transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
  flex-shrink: 0;
}

.featured-card:hover .featured-external {
  transform: translate(2px, -2px);
}

.platform-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.platform-chip {
  background: transparent;
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  padding: 3px 10px;
  font-size: 0.72rem;
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.featured-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.featured-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.featured-stat {
  background: transparent;
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  padding: 4px 12px;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--text-muted);
}

/* App screenshots strip */
.app-screenshots {
  display: flex;
  gap: 8px;
  overflow: hidden;
  border-radius: var(--radius-card);
  height: 160px;
  margin-top: 2px;
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.app-screenshot {
  height: 100%;
  width: auto;
  border-radius: var(--radius-card);
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Airline marquee */
.airline-marquee-wrap {
  overflow: hidden;
  margin: 4px -4px 0;
  border-radius: var(--radius-card);
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.airline-marquee {
  display: flex;
  align-items: center;
  gap: 20px;
  width: max-content;
  animation: airline-scroll 28s linear infinite;
}

.airline-marquee-wrap:hover .airline-marquee {
  animation-play-state: paused;
}

.airline-logo {
  width: 56px;
  height: 56px;
  object-fit: contain;
  border-radius: var(--radius-card);
  background: #fff;
  border: 1px solid var(--border-glow);
  padding: 4px;
  flex-shrink: 0;
}

@keyframes airline-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ===== Talks & Media ===== */
.talks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.talk-card {
  padding: 22px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.talk-card:hover {
  transform: scale(1.03) translateY(-2px);
}

.talk-type {
  font-size: 0.78rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.talk-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  flex: 1;
}

.talk-venue {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.talk-arrow {
  font-size: 1.1rem;
  color: var(--accent);
  align-self: flex-end;
  transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.talk-card:hover .talk-arrow {
  transform: translate(2px, -2px);
}

/* Signal bars */
.signal-bars {
  display: inline-flex;
  gap: 2px;
  align-items: flex-end;
}

.signal-bar {
  width: 3px;
  background: var(--accent-dim);
  border-radius: 1px;
}

.signal-bar:nth-child(1) { height: 3px; }
.signal-bar:nth-child(2) { height: 6px; }
.signal-bar:nth-child(3) { height: 9px; }
.signal-bar:nth-child(4) { height: 12px; }

.signal-bar.active {
  background: var(--accent);
}

/* ===== Projects ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.project-card {
  padding: 28px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.project-card:not(.project-card--placeholder):hover {
  transform: scale(1.03) translateY(-2px);
}

.project-card--placeholder {
  border: 2px dashed rgba(0, 238, 255, 0.15);
  background: transparent;
  cursor: default;
  opacity: 0.7;
}

.project-icon {
  font-size: 2rem;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.project-content {
  flex: 1;
  min-width: 0;
}

.project-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.project-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.project-arrow {
  font-size: 1.3rem;
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.project-card:not(.project-card--placeholder):hover .project-arrow {
  transform: translateX(4px);
}

/* ===== Blog / Articles ===== */
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.blog-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 22px;
  text-decoration: none;
  color: var(--text);
  overflow: hidden;
  border-radius: var(--radius-card);
}

.blog-pill:hover {
  transform: translateX(4px);
}

.log-prefix {
  font-family: var(--font-mono);
  color: var(--accent);
  margin-right: 8px;
  font-size: 0.8rem;
}

.blog-pill-text {
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.4;
}

.blog-pill-arrow {
  font-size: 1rem;
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 180ms ease;
}

.blog-pill:hover .blog-pill-arrow {
  transform: translate(2px, -2px);
}

.blog-cta {
  margin-top: 24px;
  text-align: center;
}

.cta-link {
  display: inline-block;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  font-family: var(--font-mono);
  text-decoration: none;
  padding: 12px 28px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--accent);
  transition: all 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cta-link:hover {
  background: rgba(0, 238, 255, 0.1);
  transform: scale(1.04);
  box-shadow: 0 0 24px rgba(0, 238, 255, 0.3);
}

/* ===== Testimonials ===== */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.testimonial-card {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.intercept-header {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--text-muted);
  border-bottom: 1px dashed var(--border-glow);
  padding-bottom: 8px;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.testimonial-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
  font-style: normal;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.testimonial-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--amber));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: white;
  flex-shrink: 0;
}

.testimonial-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
}

.testimonial-role {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.testimonial-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.testimonial-pill {
  background: transparent;
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-card);
  padding: 3px 10px;
  font-size: 0.72rem;
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.testimonial-card:nth-child(3n+2) .testimonial-avatar {
  background: linear-gradient(135deg, var(--amber), var(--accent));
}

.testimonial-card:nth-child(3n+3) .testimonial-avatar {
  background: linear-gradient(135deg, var(--magenta), var(--accent));
}

/* ===== Research ===== */
.research-intro {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 20px;
  line-height: 1.6;
}

.research-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.research-card {
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  position: relative;
}

.research-card:hover {
  transform: scale(1.03) translateY(-2px);
}

.classification {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--amber);
  border: 1px solid rgba(240, 160, 48, 0.3);
  padding: 2px 8px;
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 1;
}

.research-card-img {
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(0, 238, 255, 0.04), rgba(240, 160, 48, 0.02));
  overflow: hidden;
}

.research-card-img svg {
  width: 100%;
  height: 100%;
}

.research-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.research-card-body {
  padding: 18px 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.research-card-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  flex: 1;
}

.research-card-arrow {
  font-size: 1.1rem;
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.research-card:hover .research-card-arrow {
  transform: translate(2px, -2px);
}

/* ===== Footer ===== */
.footer {
  padding: 32px 0 40px;
  border-top: 1px solid var(--border-glow);
  margin-top: 40px;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-copy {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.footer-email {
  font-size: 0.875rem;
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-family: var(--font-mono);
}

.footer-email:hover {
  text-decoration: underline;
}

.footer-socials {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  font-family: var(--font-mono);
  transition: color 150ms;
}

.footer-link:hover {
  color: var(--accent);
}

/* System status */
.system-status {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
}

/* ===== Back to Top ===== */
.back-to-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(0, 238, 255, 0.2);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 300ms, transform 300ms, background 150ms, box-shadow 150ms;
  pointer-events: none;
  z-index: 50;
}

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

.back-to-top:hover {
  background: rgba(0, 238, 255, 0.1);
  box-shadow: 0 0 24px rgba(0, 238, 255, 0.4);
  transform: translateY(-2px);
}

/* ===== Custom Cursor ===== */
.cursor-dot {
  position: fixed;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10001;
  transition: transform 50ms;
  top: 0;
  left: 0;
}

.cursor-ring {
  position: fixed;
  width: 30px;
  height: 30px;
  border: 1px solid var(--accent-dim);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transition: width 200ms, height 200ms, border-color 200ms;
  top: 0;
  left: 0;
  transform: translate(-50%, -50%);
}

.cursor-ring.hover {
  width: 45px;
  height: 45px;
  border-color: var(--amber);
}

body.custom-cursor {
  cursor: none;
}

body.custom-cursor a,
body.custom-cursor button {
  cursor: none;
}

/* ===== Focus Styles ===== */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.social-link:focus-visible,
.back-to-top:focus-visible {
  border-radius: 50%;
}

/* ===== Animations ===== */
@keyframes status-pulse {
  0%, 100% { box-shadow: 0 0 4px var(--accent); }
  50% { box-shadow: 0 0 12px var(--accent), 0 0 24px rgba(0, 238, 255, 0.3); }
}

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

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
  .stars, .nebula, .starfield::before, .starfield::after, .comet {
    animation: none !important;
  }

  .hero-inner {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    will-change: auto;
  }

  .ring-outer,
  .ring-inner {
    animation: none !important;
  }

  .status-dot {
    animation: none !important;
  }

  .scan-sweep::before {
    animation: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .reveal.visible .featured-grid > *,
  .reveal.visible .timeline > .timeline-entry,
  .reveal.visible .talks-grid > *,
  .reveal.visible .testimonials-grid > *,
  .reveal.visible .research-grid > *,
  .reveal.visible .blog-list > *,
  .reveal.visible .projects-grid > *,
  .reveal.visible .stat-chips > * {
    animation: none;
    opacity: 1;
    transform: none;
    filter: none;
  }

  body::after {
    opacity: 0;
  }

  .grid-floor {
    display: none;
  }

  .cursor-dot,
  .cursor-ring {
    display: none;
  }
}

/* ===== Responsive 768px ===== */
@media (max-width: 768px) {
  .skills-grid {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
  }

  .hud-label,
  .section-hud-label .hud-label {
    display: none;
  }

  .nav-sep {
    display: none;
  }

  .grid-floor {
    display: none;
  }

  body::after {
    background: repeating-linear-gradient(
      0deg,
      rgba(0, 240, 255, 0.005) 0px,
      rgba(0, 240, 255, 0.005) 1px,
      transparent 1px,
      transparent 4px
    );
  }
}

/* ===== Responsive 600px ===== */
@media (max-width: 600px) {
  .featured-grid {
    grid-template-columns: 1fr;
  }

  .featured-card--wide {
    grid-column: auto;
  }

  .about-card {
    padding: 24px 20px;
  }

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

  .badge-dot {
    display: none;
  }

  .badge-row {
    gap: 6px;
  }

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

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

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

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

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

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

  .blog-pill {
    border-radius: var(--radius-card);
  }

  .nav-cta {
    display: none;
  }

  .hero-panel {
    padding: 24px 16px;
  }

  .holo-panel {
    background-size:
      10px 1px,
      1px 10px,
      10px 1px,
      1px 10px,
      10px 1px,
      1px 10px,
      10px 1px,
      1px 10px;
  }

  .holo-panel:hover {
    background-size:
      16px 1px,
      1px 16px,
      16px 1px,
      1px 16px,
      16px 1px,
      1px 16px,
      16px 1px,
      1px 16px;
  }
}
