/* ============================================
   CSS Variables & Design Tokens
   ============================================ */
:root {
  /* Dark theme (default) */
  --background: 220 20% 4%;
  --foreground: 0 0% 98%;

  --card: 220 20% 7%;
  --card-foreground: 0 0% 98%;

  --popover: 220 20% 7%;
  --popover-foreground: 0 0% 98%;

  /* Neon green accent */
  --primary: 82 100% 50%;
  --primary-foreground: 220 20% 4%;

  --secondary: 220 20% 12%;
  --secondary-foreground: 0 0% 98%;

  --muted: 220 15% 15%;
  --muted-foreground: 220 10% 55%;

  --accent: 82 100% 50%;
  --accent-foreground: 220 20% 4%;

  --destructive: 0 84% 60%;
  --destructive-foreground: 0 0% 98%;

  --border: 220 15% 15%;
  --input: 220 15% 15%;
  --ring: 82 100% 50%;

  --radius: 0.5rem;

  /* Custom design tokens */
  --glow-primary: 0 0 60px hsl(82 100% 50% / 0.3);
  --glow-strong: 0 0 80px hsl(82 100% 50% / 0.5);
  --gradient-primary: linear-gradient(
    135deg,
    hsl(82 100% 50%),
    hsl(82 100% 40%)
  );
  --gradient-dark: linear-gradient(180deg, hsl(220 20% 4%), hsl(220 20% 8%));
  --gradient-card: linear-gradient(135deg, hsl(220 20% 8%), hsl(220 20% 6%));

  /* Typography */
  --font-display: "Outfit", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  /* Transitions */
  --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.light {
  --background: 0 0% 98%;
  --foreground: 220 20% 10%;

  --card: 0 0% 100%;
  --card-foreground: 220 20% 10%;

  --popover: 0 0% 100%;
  --popover-foreground: 220 20% 10%;

  --primary: 82 80% 40%;
  --primary-foreground: 0 0% 100%;

  --secondary: 220 15% 85%;
  --secondary-foreground: 220 20% 10%;

  --muted: 220 15% 88%;
  --muted-foreground: 220 10% 35%;

  --accent: 82 80% 40%;
  --accent-foreground: 0 0% 100%;

  --border: 220 15% 75%;
  --input: 220 15% 75%;
  --ring: 82 80% 40%;

  --glow-primary: 0 0 40px hsl(82 80% 40% / 0.2);
  --glow-strong: 0 0 60px hsl(82 80% 40% / 0.3);
  --gradient-primary: linear-gradient(135deg, hsl(82 80% 40%), hsl(82 80% 30%));
  --gradient-dark: linear-gradient(180deg, hsl(0 0% 98%), hsl(220 15% 90%));
  --gradient-card: linear-gradient(135deg, hsl(0 0% 100%), hsl(220 15% 95%));
}

/* ============================================
   Base Styles
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border-color: hsl(var(--border));
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* Offset for fixed navbar */
}

body {
  font-family: var(--font-display);
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

/* ============================================
   Utility Classes
   ============================================ */
.hidden {
  display: none !important;
}

.section-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .section-container {
    padding: 0 1.5rem;
  }
}

@media (min-width: 1024px) {
  .section-container {
    padding: 0 2rem;
  }
}

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.icon {
  display: inline-block;
  vertical-align: middle;
}

.mobile-only {
  display: block;
}

@media (min-width: 768px) {
  .mobile-only {
    display: none !important;
  }

  #mobile-menu-toggle {
    display: none !important;
  }
}

/* ============================================
   Loading Screen
   ============================================ */
.loading-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: hsl(var(--background));
}

.loading-screen.hidden {
  display: none;
}

.loading-scan-line {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(
    to right,
    transparent,
    hsl(var(--primary) / 0.3),
    transparent
  );
  animation: scan-line 3s linear infinite;
  z-index: 5;
}

@keyframes scan-line {
  0% {
    top: 0%;
  }
  100% {
    top: 100%;
  }
}

.loading-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
      hsl(var(--border) / 0.3) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, hsl(var(--border) / 0.3) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.2;
}

.loading-terminal {
  position: relative;
  width: 100%;
  max-width: 28rem;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card) / 0.8);
  backdrop-filter: blur(8px);
  padding: 1.5rem;
  animation: scale-in 0.5s ease-out;
  z-index: 10;
}

@keyframes scale-in {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.terminal-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.terminal-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
}

.terminal-dot-red {
  background-color: hsl(var(--destructive));
}

.terminal-dot-yellow {
  background-color: #eab308;
}

.terminal-dot-green {
  background-color: hsl(var(--primary));
}

.terminal-title {
  margin-left: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground));
}

.terminal-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.terminal-line {
  opacity: 0;
  transform: translateX(-10px);
  animation: fade-in-left 0.3s ease-out forwards;
}

.terminal-line-green {
  color: hsl(var(--primary));
}

.terminal-cursor {
  display: inline-block;
  width: 0.5rem;
  height: 1rem;
  background-color: hsl(var(--primary));
  margin-left: 0.25rem;
  animation: terminal-blink 1s step-end infinite;
}

@keyframes terminal-blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

@keyframes fade-in-left {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.loading-progress {
  margin-top: 1.5rem;
}

.progress-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground));
}

.progress-bar {
  height: 0.25rem;
  overflow: hidden;
  border-radius: 9999px;
  background-color: hsl(var(--secondary));
}

.progress-fill {
  height: 100%;
  background-color: hsl(var(--primary));
  width: 0%;
  transition: width 0.5s ease-out;
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.loading-copyright {
  position: absolute;
  bottom: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground));
  opacity: 0.5;
  animation: fade-in 1s ease-out 1s forwards;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* ============================================
   Scroll Progress Bar
   ============================================ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 50;
  background-color: transparent;
  pointer-events: none;
}

.scroll-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--gradient-primary);
  transition: width 0.1s ease-out;
  box-shadow: 0 0 10px hsl(var(--primary) / 0.5);
  border-radius: 0 0 2px 2px;
}

/* ============================================
   Navbar
   ============================================ */
.navbar {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  z-index: 40;
  transition: var(--transition-smooth);
}

.navbar.scrolled {
  background-color: hsl(var(--background) / 0.8);
  backdrop-filter: blur(16px);
}

.navbar-content {
  display: flex;
  height: 4rem;
  align-items: center;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .navbar-content {
    height: 5rem;
  }
}

.navbar-logo {
  font-family: var(--font-mono);
  font-size: 1.125rem;
  font-weight: 700;
  color: hsl(var(--primary));
  text-decoration: none;
  transition: var(--transition-smooth);
}

.navbar-logo:hover {
  transform: scale(1.05);
}

.navbar-desktop {
  display: none;
  align-items: center;
  gap: 2rem;
}

@media (min-width: 768px) {
  .navbar-desktop {
    display: flex;
  }
}

.nav-link {
  position: relative;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: var(--transition-smooth);
}

.nav-link:hover {
  color: hsl(var(--foreground));
  transform: translateY(-2px);
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -0.25rem;
  left: 0;
  height: 2px;
  width: 0;
  background-color: hsl(var(--primary));
  transition: width 0.2s ease-out;
}

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

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

.navbar-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.navbar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 2.5rem;
  min-width: 2.5rem;
  padding: 0 0.75rem;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--secondary) / 0.5);
  color: hsl(var(--foreground));
  cursor: pointer;
  transition: var(--transition-smooth);
}

.light .navbar-btn {
  background-color: hsl(var(--secondary) / 0.8);
  border-color: hsl(var(--border));
}

#lang-toggle {
  width: auto;
  gap: 0.5rem;
}

.navbar-btn:hover {
  background-color: hsl(var(--secondary));
  transform: scale(1.05);
}

.light .navbar-btn:hover {
  background-color: hsl(var(--secondary));
  border-color: hsl(var(--border));
}

.navbar-btn:active {
  transform: scale(0.95);
}

.lang-indicator {
  margin-left: 0.25rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

/* ============================================
   Mobile Menu
   ============================================ */
.mobile-menu {
  position: fixed;
  left: 0;
  right: 0;
  top: 4rem;
  z-index: 30;
  border-bottom: 1px solid hsl(var(--border));
  background-color: hsl(var(--background) / 0.95);
  backdrop-filter: blur(16px);
  display: none;
}

@media (min-width: 768px) {
  .mobile-menu {
    display: none !important;
  }
}

.mobile-menu.show {
  display: block;
  animation: slide-down 0.3s ease-out;
}

@keyframes slide-down {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem 0;
}

.mobile-nav-link {
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: var(--transition-smooth);
}

.mobile-nav-link:hover {
  background-color: hsl(var(--secondary));
  color: hsl(var(--foreground));
}

.mobile-nav-link.active {
  background-color: hsl(var(--secondary));
  color: hsl(var(--primary));
}

/* ============================================
   Hero Section
   ============================================ */
.hero-section {
  position: relative;
  display: flex;
  min-height: 100vh;
  align-items: center;
  overflow: hidden;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
      hsl(var(--border) / 0.3) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, hsl(var(--border) / 0.3) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.3;
}

.hero-watermark {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  pointer-events: none;
  white-space: nowrap;
  font-size: 25vw;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.05em;
  color: hsl(var(--foreground));
  font-family: var(--font-display);
  z-index: 1;
  opacity: 0.4;
}

.hero-watermark.hidden {
  display: none;
}

.hero-watermark.show {
  display: flex;
  position: fixed;
  z-index: 9998;
  background-color: hsl(var(--background));
}

.hero-watermark.normal {
  display: flex;
  position: absolute;
  z-index: 1;
  background-color: transparent;
}

.hero-watermark .watermark-char {
  display: inline-block;
  opacity: 0;
  animation: watermark-fade-in 0.6s ease-out forwards;
}

@keyframes watermark-fade-in {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 0.15;
    transform: translateY(0);
  }
}

/* After animation, reduce opacity */
.hero-watermark.show .watermark-char {
  animation: watermark-fade-in 0.6s ease-out forwards,
    watermark-fade-out 0.8s ease-out 2.5s forwards;
}

.hero-watermark.normal .watermark-char {
  opacity: 0.4;
  transform: translateY(0);
}

@keyframes watermark-fade-out {
  to {
    opacity: 0.3;
  }
}

.hero-content.hidden {
  opacity: 0;
  pointer-events: none;
}

.hero-content.show {
  opacity: 1;
  pointer-events: auto;
  animation: fade-in-up 0.6s ease-out forwards;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
}

.hero-glow-1 {
  left: 25%;
  top: 25%;
  width: 24rem;
  height: 24rem;
  background-color: hsl(var(--primary) / 0.1);
}

.hero-glow-2 {
  bottom: 25%;
  right: 25%;
  width: 16rem;
  height: 16rem;
  background-color: hsl(var(--primary) / 0.05);
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 56rem;
}

.hero-greeting {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  animation: fade-in-up 0.6s ease-out 0.2s both;
}

.greeting-line {
  height: 1px;
  width: 3rem;
  background-color: hsl(var(--primary));
}

.greeting-text {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--primary));
}

.greeting-name {
  color: hsl(var(--foreground));
}

.hero-title {
  margin-bottom: 1.5rem;
  font-size: 3rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.025em;
  text-transform: uppercase;
  font-family: var(--font-display);
  animation: fade-in-up 0.6s ease-out 0.3s both;
}

@media (min-width: 640px) {
  .hero-title {
    font-size: 4.5rem;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 5rem;
  }
}

.hero-description {
  margin-bottom: 2rem;
  max-width: 36rem;
  font-size: 1.125rem;
  color: hsl(var(--muted-foreground));
  animation: fade-in-up 0.6s ease-out 0.5s both;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  animation: fade-in-up 0.6s ease-out 0.6s both;
}

@media (min-width: 640px) {
  .hero-actions {
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
  }
}

.hero-btn {
  position: relative;
  overflow: hidden;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  border: none;
  background-color: hsl(var(--primary));
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
  color: hsl(var(--primary-foreground));
  cursor: pointer;
  transition: var(--transition-smooth);
}

.hero-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background-color: hsl(var(--foreground));
  transform: translateX(-100%);
  transition: transform 0.3s ease-out;
}

.hero-btn:hover::before {
  transform: translateX(0);
}

.hero-btn:hover {
  transform: scale(1.02);
}

.hero-btn:active {
  transform: scale(0.98);
}

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

.hero-location {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: hsl(var(--muted-foreground));
}

.hero-location .icon {
  color: hsl(var(--primary));
}

.hero-location span {
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  animation: fade-in 1s ease-out 1s both, float 2s ease-in-out infinite 2s;
}

.hero-scroll-indicator .icon {
  color: hsl(var(--primary));
}

@keyframes float {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(10px);
  }
}

/* ============================================
   Section Styles
   ============================================ */
section {
  position: relative;
  padding: 6rem 0;
}

@media (min-width: 1024px) {
  section {
    padding: 8rem 0;
  }
}

.section-glow {
  position: absolute;
  width: 24rem;
  height: 24rem;
  border-radius: 50%;
  filter: blur(150px);
  background-color: hsl(var(--primary) / 0.05);
}

.section-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.section-header-center {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header-center .section-header {
  justify-content: center;
}

.section-line {
  height: 1px;
  width: 3rem;
  background-color: hsl(var(--primary));
}

.section-subtitle {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--primary));
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.025em;
}

@media (min-width: 1024px) {
  .section-title {
    font-size: 3rem;
  }
}

/* ============================================
   About Section
   ============================================ */
.about-section {
  position: relative;
}

.about-section .section-glow {
  right: 0;
  top: 50%;
  transform: translateY(-50%);
}

.about-grid {
  display: grid;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
  }
}

.about-text {
  display: flex;
  flex-direction: column;
}

.about-description {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  color: hsl(var(--muted-foreground));
}

.about-visual {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.terminal-card {
  position: relative;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  padding: 1.5rem;
}

.light .terminal-card {
  border-color: hsl(var(--border));
  box-shadow: 0 2px 8px hsl(var(--border) / 0.2);
}

.terminal-glow {
  position: absolute;
  inset: -0.25rem;
  z-index: -1;
  border-radius: 0.75rem;
  background-color: hsl(var(--primary) / 0.2);
  filter: blur(24px);
}

.light .terminal-glow {
  background-color: hsl(var(--primary) / 0.1);
}

.terminal-code {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.code-keyword {
  color: hsl(var(--primary));
}

.code-variable {
  color: hsl(var(--foreground));
}

.code-property {
  color: hsl(var(--primary));
}

.code-string {
  color: hsl(var(--foreground));
}

.code-indent {
  padding-left: 1rem;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.stat-card {
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card) / 0.5);
  padding: 1rem;
  text-align: center;
}

.light .stat-card {
  background-color: hsl(var(--card));
  border-color: hsl(var(--border));
  box-shadow: 0 2px 4px hsl(var(--border) / 0.2);
}

.stat-icon {
  margin: 0 auto 0.5rem;
  color: hsl(var(--primary));
}

.stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: hsl(var(--foreground));
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground));
}

/* ============================================
   Services Section
   ============================================ */
.services-section {
  background: linear-gradient(
    to bottom,
    hsl(var(--background)),
    hsl(var(--secondary) / 0.2),
    hsl(var(--background))
  );
}

.services-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.service-card {
  position: relative;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  padding: 2rem;
  transition: var(--transition-smooth);
}

.service-card:hover {
  border-color: hsl(var(--primary) / 0.5);
  background-color: hsl(var(--card) / 0.8);
}

.light .service-card:hover {
  border-color: hsl(var(--border));
  background-color: hsl(var(--card));
}

.service-icon {
  display: inline-flex;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--secondary) / 0.5);
  padding: 0.75rem;
  color: hsl(var(--primary));
  transition: var(--transition-smooth);
  margin-bottom: 1.5rem;
}

.light .service-icon {
  background-color: hsl(var(--secondary) / 0.8);
  border-color: hsl(var(--border));
}

.service-card:hover .service-icon {
  border-color: hsl(var(--primary) / 0.5);
  background-color: hsl(var(--primary) / 0.1);
}

.light .service-card:hover .service-icon {
  border-color: hsl(var(--primary) / 0.6);
  background-color: hsl(var(--primary) / 0.15);
}

.service-number {
  position: absolute;
  right: 1.5rem;
  top: 1.5rem;
  font-family: var(--font-mono);
  font-size: 2.25rem;
  font-weight: 700;
  color: hsl(var(--border));
  transition: var(--transition-smooth);
}

.light .service-number {
  color: hsl(var(--muted-foreground) / 0.4);
}

.service-card:hover .service-number {
  color: hsl(var(--primary) / 0.2);
}

.light .service-card:hover .service-number {
  color: hsl(var(--primary) / 0.3);
}

.service-title {
  margin-bottom: 0.75rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.service-description {
  color: hsl(var(--muted-foreground));
}

/* ============================================
   Process Section
   ============================================ */
.process-section {
  position: relative;
}

.process-section .section-header {
  justify-content: center;
}

.process-section .section-title {
  text-align: center;
}

.process-glow {
  left: 0;
  top: 50%;
  transform: translateY(-50%);
}

.process-timeline {
  position: relative;
}

.process-line {
  position: absolute;
  left: 1.6875rem;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(
    to bottom,
    hsl(var(--primary)),
    hsl(var(--primary) / 0.5),
    transparent
  );
  display: none;
}

@media (min-width: 768px) {
  .process-line {
    left: 50%;
    display: block;
    transform: translateX(-1px);
  }
}

.process-step {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 4rem;
  transition: var(--transition-smooth);
  cursor: pointer;
}

.process-step:last-child {
  margin-bottom: 0;
}

.process-step:hover {
  transform: translateY(-2px);
}

@media (min-width: 768px) {
  .process-step {
    margin-bottom: 3rem;
    justify-content: center;
  }

  .process-step:last-child {
    margin-bottom: 0;
  }

  .process-step-left {
    flex-direction: row;
  }

  .process-step-right {
    flex-direction: row-reverse;
  }
}

.process-number {
  position: absolute;
  left: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  border: 2px solid hsl(var(--primary));
  background-color: hsl(var(--background));
  font-family: var(--font-mono);
  font-size: 1.125rem;
  font-weight: 700;
  color: hsl(var(--primary));
  transition: var(--transition-smooth);
}

.process-step:hover .process-number {
  background-color: hsl(var(--primary) / 0.15);
  border-color: hsl(var(--primary));
  box-shadow: 0 0 20px hsl(var(--primary) / 0.3);
}

@media (min-width: 768px) {
  .process-number {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    flex-shrink: 0;
    z-index: 10;
  }

  .process-step:hover .process-number {
    transform: translateX(-50%) scale(1.1);
  }
}

.process-card {
  margin-left: 5rem;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  padding: 2rem;
  transition: var(--transition-smooth);
}

.process-step:hover .process-card {
  border-color: hsl(var(--primary) / 0.6);
  background-color: hsl(var(--card) / 0.95);
  box-shadow: 0 4px 20px hsl(var(--primary) / 0.1);
  transform: translateX(4px);
}

.process-step-right:hover .process-card {
  transform: translateX(-4px);
}

@media (min-width: 768px) {
  .process-card {
    margin-left: 0;
    width: calc(50% - 4rem);
    flex-shrink: 0;
  }

  .process-step-left .process-card {
    margin-right: auto;
    margin-left: 2rem;
    text-align: left;
  }

  .process-step-right .process-card {
    margin-left: auto;
    margin-right: 2rem;
    text-align: left;
  }
}

.process-title {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.process-description {
  color: hsl(var(--muted-foreground));
}

/* ============================================
   Projects Section
   ============================================ */
.projects-section {
  background: linear-gradient(
    to bottom,
    hsl(var(--background)),
    hsl(var(--secondary) / 0.2),
    hsl(var(--background))
  );
}

.projects-grid {
  display: grid;
  gap: 2rem;
  grid-auto-rows: min-content;
}

@media (min-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(3, 1fr);
    grid-auto-flow: row dense;
  }
}

.project-card {
  position: relative;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  overflow: hidden;
  transition: var(--transition-smooth);
}

/* Project card without images - smaller height, compact layout */
.project-card.no-images {
  grid-row: span 1;
  min-height: fit-content;
}

.project-card.no-images .project-content {
  padding: 1.25rem 1.5rem;
}

/* Project card with images - normal height (span 2 rows for no-images cards to fit) */
@media (min-width: 1024px) {
  .project-card:not(.no-images) {
    grid-row: span 2;
    min-height: 0;
  }
}

.project-card:hover {
  border-color: hsl(var(--primary) / 0.5);
}

.light .project-card:hover {
  border-color: hsl(var(--border));
  box-shadow: 0 4px 12px hsl(var(--border) / 0.3);
}

.project-image {
  position: relative;
  aspect-ratio: 16 / 9;
  background-color: hsl(var(--secondary) / 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.light .project-image {
  background-color: hsl(var(--secondary) / 0.8);
  border-bottom: 1px solid hsl(var(--border));
}

/* Hide image section when no images */
.project-card.no-images .project-image {
  display: none;
}

.project-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: var(--transition-smooth);
}

.project-img.loaded {
  opacity: 1;
}

.project-placeholder {
  position: relative;
  z-index: 1;
  font-family: var(--font-mono);
  font-size: 3rem;
  font-weight: 700;
  color: hsl(var(--muted-foreground) / 0.3);
  transition: var(--transition-smooth);
}

.light .project-placeholder {
  color: hsl(var(--muted-foreground) / 0.4);
}

.project-img.loaded ~ .project-placeholder {
  display: none;
}

.project-card:hover .project-placeholder {
  color: hsl(var(--primary) / 0.3);
}

.light .project-card:hover .project-placeholder {
  color: hsl(var(--primary) / 0.4);
}

.project-content {
  padding: 1.5rem;
}

.project-status {
  display: inline-block;
  border-radius: 9999px;
  padding: 0.375rem 0.875rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.project-status.status-active {
  background-color: hsl(142 76% 36% / 0.15);
  color: hsl(142 76% 36%);
  border: 1px solid hsl(142 76% 36% / 0.3);
}

.project-status.status-completed {
  background-color: hsl(217 91% 60% / 0.15);
  color: hsl(217 91% 60%);
  border: 1px solid hsl(217 91% 60% / 0.3);
}

.project-status.status-archived {
  background-color: hsl(var(--muted) / 0.5);
  color: hsl(var(--muted-foreground));
  border: 1px solid hsl(var(--border));
}

.light .project-status.status-archived {
  background-color: hsl(var(--muted) / 0.8);
  border-color: hsl(var(--border));
}

.project-status.status-prototype {
  background-color: hsl(38 92% 50% / 0.15);
  color: hsl(38 92% 50%);
  border: 1px solid hsl(38 92% 50% / 0.3);
}

.project-status.status-beta {
  background-color: hsl(271 81% 56% / 0.15);
  color: hsl(271 81% 56%);
  border: 1px solid hsl(271 81% 56% / 0.3);
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.project-tag {
  border-radius: 9999px;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--secondary) / 0.5);
  padding: 0.25rem 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground));
}

.light .project-tag {
  background-color: hsl(var(--secondary) / 0.8);
  border-color: hsl(var(--border));
}

.project-title {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.project-description {
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
}

.project-actions {
  display: flex;
  gap: 0.75rem;
}

.project-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--secondary) / 0.5);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: hsl(var(--foreground));
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.project-btn:hover {
  border-color: hsl(var(--primary));
  color: hsl(var(--primary));
}

.project-btn-primary {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border: none;
}

.project-btn-primary:hover {
  background-color: hsl(var(--primary) / 0.9);
  color: hsl(var(--primary-foreground));
}

.light .project-btn {
  background-color: hsl(var(--secondary) / 0.8);
  border-color: hsl(var(--border));
}

.light .project-btn:hover {
  border-color: hsl(var(--primary));
  background-color: hsl(var(--secondary) / 0.9);
}

.projects-note {
  margin-top: 3rem;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
}

/* ============================================
   Contact Section
   ============================================ */
.contact-section {
  position: relative;
}

.contact-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 24rem;
  height: 24rem;
  border-radius: 50%;
  background-color: hsl(var(--primary) / 0.1);
  filter: blur(150px);
}

.contact-content {
  max-width: 56rem;
  margin: 0 auto;
  text-align: center;
}

.contact-description {
  margin-bottom: 3rem;
  font-size: 1.125rem;
  color: hsl(var(--muted-foreground));
}

.contact-cards {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .contact-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

.contact-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  padding: 2rem;
  text-decoration: none;
  transition: var(--transition-smooth);
}

.contact-card:hover {
  border-color: hsl(var(--primary) / 0.5);
}

.contact-icon {
  display: inline-flex;
  border-radius: 50%;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--secondary) / 0.5);
  padding: 1rem;
  color: hsl(var(--primary));
  transition: var(--transition-smooth);
  margin-bottom: 1rem;
}

.contact-card:hover .contact-icon {
  border-color: hsl(var(--primary) / 0.5);
  background-color: hsl(var(--primary) / 0.1);
}

.contact-card-title {
  margin-bottom: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: hsl(var(--foreground));
}

.contact-email,
.contact-discord {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  color: hsl(var(--primary));
  transition: var(--transition-smooth);
}

.contact-card:hover .contact-email,
.contact-card:hover .contact-discord {
  letter-spacing: 0.05em;
}

.contact-arrow {
  position: absolute;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  color: hsl(var(--primary));
  transition: var(--transition-smooth);
}

.contact-card:hover .contact-arrow {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

/* ============================================
   Footer
   ============================================ */
.footer {
  position: relative;
  border-top: 1px solid hsl(var(--border));
  padding: 2rem 0;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
  }
}

.footer-logo {
  font-family: var(--font-mono);
  font-size: 1.125rem;
  font-weight: 700;
  color: hsl(var(--primary));
  text-decoration: none;
  transition: var(--transition-smooth);
}

.footer-logo:hover {
  transform: scale(1.05);
}

.footer-copyright {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.footer-link {
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: var(--transition-smooth);
}

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

.footer-separator {
  color: hsl(var(--muted-foreground));
}

/* ============================================
   Cookie Consent Banner
   ============================================ */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 60;
  padding: 1rem;
  background-color: hsl(var(--card) / 0.98);
  backdrop-filter: blur(16px);
  border-top: 1px solid hsl(var(--border));
  box-shadow: 0 -4px 20px hsl(var(--background) / 0.5);
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.cookie-consent.show {
  transform: translateY(0);
}

.cookie-consent-content {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

@media (min-width: 768px) {
  .cookie-consent-content {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.cookie-consent-text {
  flex: 1;
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
  text-align: center;
}

@media (min-width: 768px) {
  .cookie-consent-text {
    text-align: left;
  }
}

.cookie-consent-text p {
  margin: 0;
  line-height: 1.6;
}

.cookie-consent-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
}

@media (min-width: 768px) {
  .cookie-consent-actions {
    flex-wrap: nowrap;
    justify-content: flex-end;
  }
}

.cookie-consent-link {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--primary));
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: var(--transition-smooth);
}

.cookie-consent-link:hover {
  color: hsl(var(--primary) / 0.8);
}

.cookie-consent-btn {
  padding: 0.625rem 1.25rem;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.cookie-consent-btn-accept {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border-color: hsl(var(--primary));
}

.cookie-consent-btn-accept:hover {
  background-color: hsl(var(--primary) / 0.9);
  transform: translateY(-2px);
  box-shadow: var(--glow-primary);
}

.cookie-consent-btn-reject {
  background-color: hsl(var(--secondary) / 0.5);
  color: hsl(var(--foreground));
}

.cookie-consent-btn-reject:hover {
  background-color: hsl(var(--secondary));
  transform: translateY(-2px);
}

.light .cookie-consent {
  background-color: hsl(var(--card) / 0.98);
  border-top-color: hsl(var(--border));
}

.light .cookie-consent-btn-reject {
  background-color: hsl(var(--secondary) / 0.8);
}

/* ============================================
   Info Modal (Cookies Policy)
   ============================================ */
.info-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.info-modal.show {
  display: flex;
  animation: fade-in 0.3s ease-out;
}

.info-modal-backdrop {
  position: absolute;
  inset: 0;
  background-color: hsl(var(--background) / 0.95);
  backdrop-filter: blur(8px);
}

.info-modal-content {
  position: relative;
  width: 100%;
  max-width: 50rem;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
  padding: 2rem;
  animation: scale-in 0.3s ease-out;
}

.info-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  cursor: pointer;
  transition: var(--transition-smooth);
}

.info-modal-close:hover {
  border-color: hsl(var(--primary) / 0.5);
  background-color: hsl(var(--primary) / 0.1);
  color: hsl(var(--primary));
}

.info-modal-body {
  padding-top: 0.5rem;
}

.info-modal-title {
  margin-bottom: 1.5rem;
  font-size: 1.875rem;
  font-weight: 700;
  color: hsl(var(--foreground));
}

.info-modal-text {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: hsl(var(--muted-foreground));
}

.info-modal-text p {
  margin-bottom: 1rem;
}

.info-modal-text p:last-child {
  margin-bottom: 0;
}

.info-modal-text strong {
  color: hsl(var(--foreground));
  font-weight: 600;
}

.info-modal-text ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
  list-style-type: disc;
}

.info-modal-text li {
  margin-bottom: 0.5rem;
}

.info-modal-text li:last-child {
  margin-bottom: 0;
}

@media (max-width: 640px) {
  .info-modal-content {
    padding: 1.5rem;
  }

  .info-modal-title {
    font-size: 1.5rem;
  }

  .info-modal-close {
    top: 0.75rem;
    right: 0.75rem;
    width: 2rem;
    height: 2rem;
  }
}

/* ============================================
   Gallery Modal
   ============================================ */
.gallery-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
}

.gallery-modal.show {
  display: flex;
  animation: fade-in 0.3s ease-out;
}

.gallery-backdrop {
  position: absolute;
  inset: 0;
  background-color: hsl(var(--background) / 0.95);
  backdrop-filter: blur(8px);
}

.gallery-content {
  position: relative;
  width: 100%;
  max-width: 80rem;
  margin: 0 1rem;
  animation: scale-in 0.3s ease-out;
}

.gallery-close {
  position: absolute;
  top: -3rem;
  right: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
  background: none;
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.gallery-close:hover {
  color: hsl(var(--foreground));
}

.gallery-image-container {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card));
}

.gallery-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: hsl(var(--card));
}

.gallery-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: hsl(var(--secondary) / 0.5);
}

.gallery-placeholder-icon {
  margin-bottom: 1rem;
  color: hsl(var(--muted-foreground));
}

.gallery-placeholder-text {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
}

.gallery-placeholder-info {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: hsl(var(--muted-foreground) / 0.5);
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--background) / 0.8);
  backdrop-filter: blur(8px);
  color: hsl(var(--foreground));
  cursor: pointer;
  transition: var(--transition-smooth);
}

.gallery-nav:hover {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}

.gallery-nav-prev {
  left: 1rem;
}

.gallery-nav-next {
  right: 1rem;
}

.gallery-dots {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
}

.gallery-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background-color: hsl(var(--muted-foreground) / 0.5);
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.gallery-dot.active {
  background-color: hsl(var(--primary));
}

/* ============================================
   Animations
   ============================================ */
@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fade-in-up 0.6s ease-out both;
}

/* ============================================
   Scroll to Top Button
   ============================================ */
.scroll-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--card) / 0.9);
  backdrop-filter: blur(8px);
  color: hsl(var(--foreground));
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(1rem);
  transition: var(--transition-smooth);
}

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

.scroll-to-top:hover {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border-color: hsl(var(--primary));
  transform: translateY(-4px);
  box-shadow: var(--glow-primary);
}

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

.light .scroll-to-top {
  background-color: hsl(var(--card) / 0.95);
  border-color: hsl(var(--border));
}

.light .scroll-to-top:hover {
  background-color: hsl(var(--primary));
  border-color: hsl(var(--primary));
}

@media (max-width: 640px) {
  .scroll-to-top {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 2.75rem;
    height: 2.75rem;
  }
}

/* ============================================
   Parallax Effects
   ============================================ */
.hero-glow,
.section-glow,
.hero-grid {
  will-change: transform;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
  perspective: 1000px;
}

/* ============================================
   Scrollbar
   ============================================ */
::-webkit-scrollbar {
  width: 8px;
}

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

::-webkit-scrollbar-thumb {
  background: hsl(var(--muted));
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: hsl(var(--primary));
}
