/* ============================================
   CSS Variables & Design Tokens
   ============================================ */
:root {
  /* Colors - Light Mode */
  --primary: #6366f1;
  --primary-light: #818cf8;
  --primary-dark: #4f46e5;
  --primary-glow: rgba(99, 102, 241, 0.15);
  --accent: #06b6d4;
  --accent-light: #22d3ee;

  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-tertiary: #f1f5f9;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --bg-nav: rgba(255, 255, 255, 0.8);
  --bg-nav-scrolled: rgba(255, 255, 255, 0.92);

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-tertiary: #94a3b8;
  --text-inverse: #ffffff;

  --border-color: #e2e8f0;
  --border-light: #f1f5f9;
  --border-focus: #6366f1;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.1);
  --shadow-primary: 0 4px 20px rgba(99, 102, 241, 0.2);

  --gradient-primary: linear-gradient(135deg, #6366f1, #06b6d4);
  --gradient-subtle: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(6, 182, 212, 0.05));
  --gradient-card: linear-gradient(135deg, rgba(99, 102, 241, 0.03), rgba(6, 182, 212, 0.03));
  --gradient-hero: linear-gradient(135deg, #f8fafc 0%, #eef2ff 50%, #f0f9ff 100%);

  /* Glass */
  --glass-bg: rgba(255, 255, 255, 0.6);
  --glass-border: rgba(255, 255, 255, 0.3);
  --glass-blur: 20px;

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --font-display: 'Outfit', 'Inter', sans-serif;

  /* Spacing scale */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Border radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
  --transition-theme: 0.4s ease;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 900px;
  --nav-height: 72px;
}

/* Dark Mode */
[data-theme="dark"] {
  --bg-primary: #0b0f1a;
  --bg-secondary: #111827;
  --bg-tertiary: #1e293b;
  --bg-card: #151c2c;
  --bg-card-hover: #1a2332;
  --bg-nav: rgba(11, 15, 26, 0.8);
  --bg-nav-scrolled: rgba(11, 15, 26, 0.92);

  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-tertiary: #64748b;
  --text-inverse: #0f172a;

  --border-color: #1e293b;
  --border-light: #1e293b;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.5);
  --shadow-primary: 0 4px 20px rgba(99, 102, 241, 0.15);

  --gradient-subtle: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(6, 182, 212, 0.08));
  --gradient-card: linear-gradient(135deg, rgba(99, 102, 241, 0.06), rgba(6, 182, 212, 0.06));
  --gradient-hero: linear-gradient(135deg, #0b0f1a 0%, #111827 50%, #0b1120 100%);

  --glass-bg: rgba(21, 28, 44, 0.6);
  --glass-border: rgba(30, 41, 59, 0.5);

  --primary-glow: rgba(99, 102, 241, 0.1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  transition: background-color var(--transition-theme), color var(--transition-theme);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

ul, ol {
  list-style: none;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

input, textarea {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
}

/* ============================================
   Utility Classes
   ============================================ */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.container--narrow {
  max-width: var(--container-narrow);
}

.section {
  padding: var(--space-4xl) 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--primary);
  letter-spacing: 0.05em;
  margin-bottom: var(--space-md);
  padding: var(--space-xs) var(--space-md);
  background: var(--primary-glow);
  border-radius: var(--radius-full);
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.section-subtitle {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn--primary {
  background: var(--gradient-primary);
  color: var(--text-inverse);
  box-shadow: var(--shadow-primary);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(99, 102, 241, 0.35);
}

.btn--secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

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

.btn--outline {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}

.btn--outline:hover {
  background: var(--primary);
  color: var(--text-inverse);
  transform: translateY(-2px);
}

.btn--ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
}

.btn--ghost:hover {
  color: var(--primary);
  background: var(--primary-glow);
}

.btn--sm {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}

.btn--lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}

.btn svg,
.btn i {
  width: 18px;
  height: 18px;
}

/* Focus visible */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Skip Link */
.skip-link {
  position: fixed;
  top: -100%;
  left: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  background: var(--primary);
  color: white;
  border-radius: var(--radius-sm);
  z-index: 10000;
  font-size: 0.9rem;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: var(--space-md);
}

/* ============================================
   Scroll Progress
   ============================================ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--gradient-primary);
  z-index: 10001;
  transition: width 0.1s linear;
  border-radius: 0 2px 2px 0;
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  z-index: 1000;
  background: transparent;
  transition: all var(--transition-base);
}

.navbar.scrolled {
  background: var(--bg-nav-scrolled);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-primary);
  z-index: 1001;
}

.nav-logo-icon {
  width: 36px;
  height: 36px;
  background: var(--gradient-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 800;
  font-size: 1rem;
  font-family: var(--font-mono);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.nav-link {
  padding: 0.5rem 0.85rem;
  font-size: 0.9rem;
  font-weight: 450;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  position: relative;
}

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

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  z-index: 1001;
}

.theme-toggle {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
}

.theme-toggle:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--primary-glow);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  display: none;
}

[data-theme="light"] .theme-toggle .icon-moon {
  display: block;
}

[data-theme="dark"] .theme-toggle .icon-sun {
  display: block;
}

.nav-cv-btn {
  display: none;
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  z-index: 1001;
  cursor: pointer;
}

.hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  margin: 2px auto;
  border-radius: 2px;
  transition: all var(--transition-base);
}

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

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

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

/* ============================================
   Hero Section
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
  padding-top: var(--nav-height);
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
}

.hero-bg-shape--1 {
  width: 500px;
  height: 500px;
  background: rgba(99, 102, 241, 0.12);
  top: -100px;
  right: -100px;
}

.hero-bg-shape--2 {
  width: 400px;
  height: 400px;
  background: rgba(6, 182, 212, 0.1);
  bottom: -80px;
  left: -80px;
}

.hero-bg-shape--3 {
  width: 300px;
  height: 300px;
  background: rgba(168, 85, 247, 0.08);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--border-light) 1px, transparent 1px),
    linear-gradient(90deg, var(--border-light) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.4;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3xl);
  align-items: center;
  position: relative;
  z-index: 1;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.4rem 1rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  color: #10b981;
  margin-bottom: var(--space-xl);
  font-weight: 500;
}

.hero-badge-dot {
  width: 8px;
  height: 8px;
  background: #10b981;
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero-greeting {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  color: var(--text-secondary);
  font-weight: 400;
  margin-bottom: var(--space-sm);
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.hero-title-wrapper {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
  min-height: 2.2rem;
}

.hero-title-prefix {
  font-family: var(--font-mono);
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--text-tertiary);
}

.hero-title-typed {
  font-family: var(--font-mono);
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--primary);
  font-weight: 600;
  position: relative;
}

.hero-title-typed::after {
  content: '|';
  animation: blink-caret 0.8s step-end infinite;
  color: var(--primary);
  margin-left: 2px;
}

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

.hero-description {
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-xl);
  max-width: 520px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.hero-social {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.hero-social-link {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  transition: all var(--transition-base);
  box-shadow: var(--shadow-sm);
}

.hero-social-link:hover {
  color: var(--primary);
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.hero-social-link svg {
  width: 20px;
  height: 20px;
}

/* Hero Image */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-image-wrapper {
  position: relative;
  width: 380px;
  height: 380px;
}

.hero-image-frame {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
  background: var(--gradient-subtle);
  border: 2px solid var(--border-color);
  box-shadow: var(--shadow-xl);
}

.hero-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--gradient-subtle);
  color: var(--text-tertiary);
  font-size: 0.9rem;
}

.hero-image-placeholder svg {
  width: 80px;
  height: 80px;
  margin-bottom: var(--space-md);
  opacity: 0.3;
}

.hero-float-card {
  position: absolute;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.85rem;
  font-weight: 500;
  z-index: 2;
  backdrop-filter: blur(10px);
}

.hero-float-card--exp {
  top: 15%;
  right: -30px;
  animation: float 4s ease-in-out infinite;
}

.hero-float-card--projects {
  bottom: 20%;
  left: -30px;
  animation: float 4s ease-in-out infinite 1s;
}

.hero-float-card--tech {
  bottom: 5%;
  right: 10%;
  animation: float 4s ease-in-out infinite 2s;
}

.hero-float-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.hero-float-icon--purple {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
}

.hero-float-icon--green {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.hero-float-icon--blue {
  background: rgba(6, 182, 212, 0.1);
  color: var(--accent);
}

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

/* ============================================
   About Section
   ============================================ */
.about {
  background: var(--bg-primary);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: var(--space-3xl);
  align-items: start;
}

.about-image-container {
  position: relative;
}

.about-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--gradient-subtle);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 5;
}

.about-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  gap: var(--space-sm);
  min-height: 400px;
}

.about-image-placeholder svg {
  width: 60px;
  height: 60px;
  opacity: 0.3;
}

.about-content h3 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 700;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.about-text {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-lg);
}

.about-info-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}

.about-info-card {
  padding: var(--space-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.about-info-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.about-info-card-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--primary-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-sm);
  font-size: 1.1rem;
}

.about-info-card-label {
  font-size: 0.8rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-xs);
}

.about-info-card-value {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

/* ============================================
   Skills Section
   ============================================ */
.skills {
  background: var(--bg-secondary);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
}

.skill-category {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: all var(--transition-base);
}

.skill-category:hover {
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.skill-category-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.skill-category-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
}

.skill-category-title {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.skill-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.4rem 0.85rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
  font-weight: 450;
}

.skill-tag:hover {
  background: var(--primary-glow);
  border-color: rgba(99, 102, 241, 0.2);
  color: var(--primary);
  transform: translateY(-1px);
}

.skill-tag svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   Experience Section
   ============================================ */
.experience {
  background: var(--bg-primary);
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border-color);
}

.timeline-item {
  position: relative;
  padding-left: var(--space-3xl);
  padding-bottom: var(--space-2xl);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -7px;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid var(--bg-primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
  z-index: 1;
}

.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--primary);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: all var(--transition-base);
}

.timeline-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.timeline-title {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
}

.timeline-company {
  font-size: 0.95rem;
  color: var(--primary);
  font-weight: 500;
  margin-bottom: var(--space-md);
}

.timeline-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: var(--space-md);
}

.timeline-achievements {
  margin-bottom: var(--space-md);
}

.timeline-achievements li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: var(--space-sm);
  line-height: 1.6;
}

.timeline-achievements li::before {
  content: '▹';
  color: var(--primary);
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 1px;
}

.timeline-tech {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.timeline-tech-tag {
  padding: 0.25rem 0.65rem;
  background: var(--primary-glow);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  color: var(--primary);
  font-weight: 500;
  font-family: var(--font-mono);
}

/* ============================================
   Projects Section
   ============================================ */
.projects {
  background: var(--bg-secondary);
}

.project-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-2xl);
}

.filter-btn {
  padding: 0.5rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 450;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

.filter-btn.active {
  background: var(--gradient-primary);
  color: white;
  border-color: transparent;
  box-shadow: var(--shadow-primary);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: var(--space-xl);
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-base);
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: rgba(99, 102, 241, 0.3);
}

.project-card-image {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--gradient-subtle);
}

.project-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

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

.project-card-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--gradient-card);
  color: var(--text-tertiary);
  font-size: 0.85rem;
}

.project-card-image-placeholder svg {
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-sm);
  opacity: 0.3;
}

.project-card-category {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  padding: 0.3rem 0.7rem;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(10px);
  color: white;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.project-card-body {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.project-card-title {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.project-card-description {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: var(--space-md);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.project-card-tech {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-bottom: var(--space-lg);
}

.project-card-tech span {
  padding: 0.2rem 0.55rem;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-weight: 500;
}

.project-card-actions {
  display: flex;
  gap: var(--space-sm);
  margin-top: auto;
}

.project-card-actions .btn {
  flex: 1;
  padding: 0.55rem 0.85rem;
  font-size: 0.85rem;
}

/* ============================================
   Services Section
   ============================================ */
.services {
  background: var(--bg-primary);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(99, 102, 241, 0.2);
}

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

.service-card-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  font-size: 1.4rem;
  color: white;
}

.service-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.service-card-description {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ============================================
   Process Section
   ============================================ */
.process {
  background: var(--bg-secondary);
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
}

.process-card {
  text-align: center;
  padding: var(--space-xl);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  position: relative;
  transition: all var(--transition-base);
}

.process-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(99, 102, 241, 0.2);
}

.process-number {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: var(--space-md);
}

.process-card-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.process-card-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   Statistics Section
   ============================================ */
.statistics {
  background: var(--bg-primary);
  position: relative;
}

.statistics-bg {
  position: absolute;
  inset: 0;
  background: var(--gradient-subtle);
  opacity: 0.5;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  position: relative;
  z-index: 1;
}

.stat-card {
  text-align: center;
  padding: var(--space-xl);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(99, 102, 241, 0.2);
}

.stat-number {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: var(--space-sm);
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 450;
}

/* ============================================
   Contact Section
   ============================================ */
.contact {
  background: var(--bg-secondary);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: var(--space-3xl);
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
}

.contact-info h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.contact-info-text {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-lg);
}

.contact-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.contact-item:hover {
  border-color: var(--primary);
  transform: translateX(4px);
}

.contact-item-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--primary-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.1rem;
}

.contact-item-label {
  font-size: 0.8rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.contact-item-value {
  font-weight: 500;
  color: var(--text-primary);
  font-size: 0.95rem;
}

.contact-form-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  transition: all var(--transition-fast);
  font-size: 0.95rem;
}

.form-input:focus,
.form-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
  background: var(--bg-card);
}

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

.form-input.error,
.form-textarea.error {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-error {
  font-size: 0.8rem;
  color: #ef4444;
  margin-top: var(--space-xs);
  display: none;
}

.form-error.visible {
  display: block;
}

.form-submit {
  width: 100%;
  padding: 1rem;
  font-weight: 600;
}

/* Toast Notification */
.toast {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  padding: var(--space-md) var(--space-xl);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 500;
  color: white;
  z-index: 9999;
  transform: translateY(120%);
  transition: transform var(--transition-base);
  box-shadow: var(--shadow-xl);
}

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

.toast--success {
  background: #10b981;
}

.toast--error {
  background: #ef4444;
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border-color);
  padding: var(--space-3xl) 0 var(--space-xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer-brand h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: var(--space-lg);
  max-width: 320px;
}

.footer-social {
  display: flex;
  gap: var(--space-sm);
}

.footer-social-link {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.footer-social-link:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--primary-glow);
  transform: translateY(-2px);
}

.footer-social-link svg {
  width: 18px;
  height: 18px;
}

.footer-links h4 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-links ul li {
  margin-bottom: var(--space-sm);
}

.footer-links ul li a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}

.footer-links ul li a:hover {
  color: var(--primary);
}

.footer-bottom {
  padding-top: var(--space-xl);
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-copyright {
  color: var(--text-tertiary);
  font-size: 0.85rem;
}

/* Back to Top */
.back-to-top {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 44px;
  height: 44px;
  background: var(--gradient-primary);
  color: white;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-base);
  z-index: 999;
  box-shadow: var(--shadow-primary);
  border: none;
}

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

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(99, 102, 241, 0.35);
}

.back-to-top svg {
  width: 20px;
  height: 20px;
}

/* ============================================
   Project Detail Page
   ============================================ */
.project-detail-hero {
  padding: calc(var(--nav-height) + var(--space-3xl)) 0 var(--space-3xl);
  background: var(--gradient-hero);
}

.project-detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.project-detail-breadcrumb a {
  color: var(--primary);
}

.project-detail-breadcrumb a:hover {
  text-decoration: underline;
}

.project-detail-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: var(--space-md);
}

.project-detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.project-detail-meta-item {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.project-detail-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--gradient-subtle);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-xl);
  aspect-ratio: 16/9;
  margin-bottom: var(--space-3xl);
}

.project-detail-image-placeholder {
  width: 100%;
  height: 100%;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  gap: var(--space-sm);
}

.project-detail-image-placeholder svg {
  width: 60px;
  height: 60px;
  opacity: 0.3;
}

.project-detail-content {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: var(--space-3xl);
  padding-bottom: var(--space-4xl);
}

.project-detail-main h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
  margin-top: var(--space-2xl);
}

.project-detail-main h2:first-child {
  margin-top: 0;
}

.project-detail-main p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.project-detail-main ul {
  margin-bottom: var(--space-md);
}

.project-detail-main ul li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: var(--space-sm);
  line-height: 1.6;
}

.project-detail-main ul li::before {
  content: '▹';
  color: var(--primary);
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 1px;
}

.project-detail-sidebar {
  position: sticky;
  top: calc(var(--nav-height) + var(--space-xl));
  align-self: start;
}

.sidebar-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.sidebar-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.sidebar-tech-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.sidebar-tech-tag {
  padding: 0.35rem 0.75rem;
  background: var(--primary-glow);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  color: var(--primary);
  font-weight: 500;
  font-family: var(--font-mono);
}

.sidebar-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.sidebar-actions .btn {
  width: 100%;
  justify-content: center;
}

/* Related Projects */
.related-projects {
  padding: var(--space-3xl) 0;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
}

/* ============================================
   Projects Page (All Projects)
   ============================================ */
.projects-page-hero {
  padding: calc(var(--nav-height) + var(--space-3xl)) 0 var(--space-2xl);
  background: var(--gradient-hero);
  text-align: center;
}

/* ============================================
   Mobile Navigation Overlay
   ============================================ */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
}

.nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.nav-overlay .nav-link {
  font-size: 1.3rem;
  padding: var(--space-md) var(--space-xl);
  display: block;
  text-align: center;
}

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

.nav-overlay-actions {
  margin-top: var(--space-xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  align-items: center;
}

/* ============================================
   Loading / Skeleton
   ============================================ */
.skeleton {
  background: linear-gradient(90deg, var(--bg-tertiary) 25%, var(--border-light) 50%, var(--bg-tertiary) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
