:root {
  --bg: #0a0a0a;
  --bg2: #0d1117;
  --surface: #111827;
  --surface2: #1a2332;
  --teal: #10b981;
  --teal-dim: #059669;
  --teal-glow: rgba(16,185,129,0.15);
  --teal-glow2: rgba(16,185,129,0.06);
  --white: #f9fafb;
  --grey: #9ca3af;
  --grey2: #6b7280;
  --border: rgba(255,255,255,0.07);
  --border-teal: rgba(16,185,129,0.3);
}
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--white);
  font-family: 'Inter', sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
::selection { background: var(--teal); color: #000; }

.grid-bg {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(16,185,129,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16,185,129,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
}
.grid-glow {
  position: fixed; z-index: 0; pointer-events: none;
  width: 600px; height: 600px; border-radius: 50%;
  background: radial-gradient(circle, rgba(16,185,129,0.08) 0%, transparent 70%);
}
.grid-glow.top-right { top: -200px; right: -200px; }
.grid-glow.bottom-left { bottom: -200px; left: -200px; }

nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 40px; height: 60px;
  background: rgba(10,10,10,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-logo { font-weight: 800; font-size: 18px; color: var(--white); letter-spacing: -0.5px; }
.nav-links { display: flex; align-items: center; gap: 32px; font-size: 14px; font-weight: 500; color: var(--grey); }
.nav-links a:hover { color: var(--white); }
.nav-right { display: flex; align-items: center; gap: 16px; }
.lang-toggle {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 500; color: var(--grey);
  cursor: pointer; background: none; border: none;
  font-family: 'Inter', sans-serif;
}
.lang-toggle svg { width: 15px; height: 15px; }
.lang-toggle:hover { color: var(--white); }
.nav-icon { color: var(--grey); transition: color 0.15s; }
.nav-icon:hover { color: var(--teal); }
.nav-icon svg { width: 18px; height: 18px; display: block; }

section, .hero-section { position: relative; z-index: 1; }

.hero-section {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 80px 24px 60px;
}
.hero-label { font-family: 'JetBrains Mono', monospace; font-size: 14px; color: var(--teal); margin-bottom: 16px; letter-spacing: 0.02em; }
.hero-name { font-size: clamp(44px, 7vw, 80px); font-weight: 800; line-height: 1.05; letter-spacing: -2px; margin-bottom: 20px; }
.hero-title { font-size: clamp(16px, 2.5vw, 22px); font-weight: 600; color: var(--grey); max-width: 700px; margin-bottom: 24px; line-height: 1.4; }
.hero-desc { font-size: 16px; color: var(--grey2); max-width: 560px; margin: 0 auto 40px; line-height: 1.7; }
.hero-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.btn-primary {
  background: var(--teal); color: #000;
  font-weight: 600; font-size: 14px;
  padding: 12px 28px; border-radius: 50px;
  display: inline-flex; align-items: center; gap: 8px;
  transition: opacity 0.15s, transform 0.15s;
}
.btn-primary:hover { opacity: 0.88; transform: translateY(-1px); }
.btn-ghost {
  border: 1px solid var(--border-teal); color: var(--white);
  font-weight: 500; font-size: 14px;
  padding: 12px 28px; border-radius: 50px;
  transition: border-color 0.15s, transform 0.15s;
}
.btn-ghost:hover { border-color: var(--teal); transform: translateY(-1px); }
.scroll-hint { margin-top: 60px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.scroll-mouse { width: 22px; height: 36px; border: 2px solid var(--grey2); border-radius: 12px; display: flex; justify-content: center; padding-top: 6px; }
.scroll-dot { width: 3px; height: 8px; background: var(--grey2); border-radius: 2px; animation: scrollDown 1.5s ease-in-out infinite; }
@keyframes scrollDown {
  0%,100% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(8px); opacity: 0; }
}

.section { padding: 100px 24px; max-width: 1100px; margin: 0 auto; }
.section-center { text-align: center; }
.section-tag { font-family: 'JetBrains Mono', monospace; font-size: 13px; color: var(--teal); margin-bottom: 12px; display: block; }
.section-title { font-size: clamp(28px, 4vw, 40px); font-weight: 800; margin-bottom: 12px; letter-spacing: -1px; }
.section-sub { font-size: 16px; color: var(--grey); max-width: 560px; margin: 0 auto 56px; }

.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; margin-bottom: 48px; text-align: left; }
.about-text p { color: var(--grey); font-size: 15px; line-height: 1.8; margin-bottom: 20px; }
.about-text strong { color: var(--white); font-weight: 600; }
.about-cards { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.about-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 20px 16px; transition: border-color 0.2s, transform 0.2s; }
.about-card:hover { border-color: var(--border-teal); transform: translateY(-2px); }
.about-card-icon { color: var(--teal); margin-bottom: 10px; }
.about-card-label { font-size: 11px; color: var(--grey2); margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.05em; }
.about-card-value { font-size: 13px; font-weight: 600; color: var(--white); line-height: 1.4; }

.skills-section { background: var(--bg2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 100px 24px; }
.skills-inner { max-width: 1100px; margin: 0 auto; }
.skills-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.skill-card { background: var(--surface2); border: 1px solid var(--border); border-radius: 16px; padding: 32px 28px; transition: border-color 0.2s, transform 0.2s; text-align: left; }
.skill-card:hover { border-color: var(--border-teal); transform: translateY(-3px); }
.skill-card-title { font-size: 20px; font-weight: 800; margin-bottom: 24px; display: flex; align-items: center; gap: 14px; color: var(--white); letter-spacing: -0.3px; }
.skill-icon-box { width: 46px; height: 46px; border-radius: 10px; background: rgba(16,185,129,0.15); display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--teal); }
.skill-tags { display: flex; flex-wrap: wrap; gap: 10px; }
.skill-tag { font-size: 13px; font-weight: 500; padding: 8px 16px; border-radius: 8px; background: var(--surface); color: var(--white); border: 1px solid var(--border); }

.filter-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 40px; }
.filter-btn { font-size: 13px; font-weight: 500; padding: 8px 18px; border-radius: 50px; border: 1px solid var(--border); color: var(--grey); cursor: pointer; background: none; font-family: 'Inter', sans-serif; transition: all 0.15s; }
.filter-btn:hover { color: var(--white); border-color: var(--grey2); }
.filter-btn.active { background: var(--teal); color: #000; border-color: var(--teal); font-weight: 600; }

.projects-list { display: flex; flex-direction: column; gap: 16px; }
.project-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 32px 36px; transition: border-color 0.2s; }
.project-card:hover { border-color: var(--border-teal); }
.project-card[data-hidden="true"] { display: none; }
.project-name { font-size: 22px; font-weight: 800; letter-spacing: -0.5px; margin-bottom: 8px; color: var(--white); }
.project-desc { font-size: 14px; color: var(--grey); line-height: 1.7; margin-bottom: 16px; }
.project-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.project-tag { font-family: 'JetBrains Mono', monospace; font-size: 11px; padding: 4px 10px; border-radius: 6px; background: rgba(16,185,129,0.08); color: var(--teal); border: 1px solid rgba(16,185,129,0.15); }
.project-accordion { border-top: 1px solid var(--border); padding-top: 16px; margin-bottom: 16px; }
.accordion-toggle { display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-weight: 500; color: var(--teal); cursor: pointer; background: none; border: none; font-family: 'Inter', sans-serif; width: 100%; text-align: left; padding: 0; }
.accordion-toggle svg { transition: transform 0.25s; flex-shrink: 0; }
.accordion-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; font-size: 13px; color: var(--grey); line-height: 1.8; }
.accordion-body.open { max-height: 300px; padding-top: 12px; }
.project-footer { border-top: 1px solid var(--border); padding-top: 16px; }
.btn-repo { display: inline-flex; align-items: center; gap: 8px; background: rgba(16,185,129,0.12); color: var(--teal); border: 1px solid rgba(16,185,129,0.25); font-size: 13px; font-weight: 600; padding: 10px 20px; border-radius: 8px; transition: background 0.15s; }
.btn-repo:hover { background: rgba(16,185,129,0.22); }

.contact-section { background: var(--bg2); border-top: 1px solid var(--border); padding: 100px 24px; }
.contact-inner { max-width: 1100px; margin: 0 auto; text-align: center; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; max-width: 760px; margin: 0 auto 32px; }
.contact-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 22px 24px; display: flex; align-items: center; gap: 16px; text-align: left; transition: border-color 0.15s, transform 0.15s; }
.contact-card:hover { border-color: var(--border-teal); transform: translateY(-2px); }
.contact-card-icon { color: var(--teal); flex-shrink: 0; }
.contact-card-label { font-size: 11px; color: var(--grey2); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 3px; }
.contact-card-value { font-size: 14px; font-weight: 600; color: var(--white); }
.btn-cv { display: inline-flex; align-items: center; gap: 10px; background: var(--teal); color: #000; font-size: 15px; font-weight: 700; padding: 16px 40px; border-radius: 50px; transition: opacity 0.15s, transform 0.15s; }
.btn-cv:hover { opacity: 0.88; transform: translateY(-2px); }

footer { position: relative; z-index: 1; border-top: 1px solid var(--border); padding: 28px 40px; display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--grey2); flex-wrap: wrap; gap: 10px; }
footer span { display: flex; align-items: center; gap: 4px; }

#progress-bar { position: fixed; top: 0; left: 0; z-index: 200; height: 2px; width: 0%; background: linear-gradient(90deg, var(--teal), rgba(16,185,129,0.4)); transition: width 0.1s linear; box-shadow: 0 0 8px rgba(16,185,129,0.5); }

#particle-canvas { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.35; }

.fade-up { opacity: 0; transform: translateY(10px); transition: opacity 1s cubic-bezier(0.4,0,0.2,1), transform 1s cubic-bezier(0.4,0,0.2,1); }
.fade-up.visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }

.hero-label   { transition-delay: 0s !important; }
.hero-name    { transition-delay: 0.12s !important; }
.hero-title   { transition-delay: 0.22s !important; }
.hero-desc    { transition-delay: 0.32s !important; }
.hero-btns    { transition-delay: 0.42s !important; }
.scroll-hint  { transition-delay: 0.54s !important; }

.project-card { box-shadow: 0 0 0 0 rgba(16,185,129,0); transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s; }
.project-card:hover { box-shadow: 0 0 28px rgba(16,185,129,0.08), 0 6px 32px rgba(0,0,0,0.35); transform: translateY(-3px); }
.skill-card { box-shadow: 0 0 0 0 rgba(16,185,129,0); transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s; }
.skill-card:hover { box-shadow: 0 0 28px rgba(16,185,129,0.1), 0 6px 28px rgba(0,0,0,0.3); transform: translateY(-4px); }

.nav-links a { position: relative; padding-bottom: 2px; transition: color 0.2s; }
.nav-links a::after { content: ''; position: absolute; left: 0; bottom: -2px; width: 0; height: 1.5px; background: var(--teal); transition: width 0.25s cubic-bezier(0.22,1,0.36,1); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

@media (max-width: 900px) {
  nav { padding: 0 20px; }
  .nav-links { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .about-cards { grid-template-columns: repeat(2, 1fr); }
  .skills-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .project-card { padding: 24px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .fade-up { opacity: 1; transform: none; transition: none; }
  .scroll-dot { animation: none; }
}