*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0d0f14;
  --bg2:       #13161d;
  --bg3:       #1a1e28;
  --accent:    #4fffb0;
  --accent2:   #7b8cff;
  --text:      #e8eaf0;
  --muted:     #7a7f94;
  --border:    rgba(255,255,255,0.07);
  --font-head: 'Syne', sans-serif;
  --font-mono: 'DM Mono', monospace;
  --radius:    12px;
}

html { scroll-behavior: smooth; min-height: 100%; }

body {
  background: radial-gradient(ellipse, rgba(78,255,176,0.12) 0%, transparent 70%), var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font-mono);
  font-weight: 300;
  line-height: 1.7;
  font-size: 15px;
  min-height: 100vh;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 3rem;
  background: rgba(13,15,20,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-logo {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--accent);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--accent); }

/* ── HERO ── */
#hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8rem 3rem 4rem;
  position: relative;
  overflow: hidden;
}
#hero::before {
  content: '';
  position: absolute;
  top: -30%; left: -10%;
  width: 60%; height: 80%;
  background: radial-gradient(ellipse, rgba(78,255,176,0.06) 0%, transparent 70%);
  pointer-events: none;
}
#hero::after {
  content: '';
  position: absolute;
  bottom: -20%; right: -5%;
  width: 50%; height: 60%;
  background: radial-gradient(ellipse, rgba(123,140,255,0.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero-tag {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.2s;
}
.hero-name {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(3rem, 8vw, 6.5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--text);
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.4s;
}
.hero-name span { color: var(--accent); }
.hero-role {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(1.2rem, 3vw, 2rem);
  color: var(--accent2);
  margin-top: 0.8rem;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.55s;
}
.hero-desc {
  max-width: 520px;
  color: var(--muted);
  margin-top: 1.5rem;
  font-size: 0.95rem;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.7s;
}
.hero-cta {
  display: flex;
  gap: 1rem;
  margin-top: 2.5rem;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.85s;
}
.btn {
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
}
.btn-primary {
  background: var(--accent);
  color: #0d0f14;
  border: none;
}
.btn-primary:hover { background: #2de89a; transform: translateY(-2px); }
.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--accent2); color: var(--accent2); transform: translateY(-2px); }

/* ── SECTIONS ── */
section {
  padding: 6rem 3rem;
  max-width: 1100px;
  margin: 0 auto;
}
.section-label {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}
.section-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.02em;
  margin-bottom: 3rem;
  color: var(--text);
}
.divider {
  width: 100%;
  height: 1px;
  background: var(--border);
  margin: 0;
}

/* ── SKILLS ── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}
.skill-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color 0.2s, transform 0.2s;
}
.skill-card:hover {
  border-color: rgba(78,255,176,0.3);
  transform: translateY(-3px);
}
.skill-card-title {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--accent);
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.skill-dot {
  width: 7px; height: 7px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}
.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
}
.skill-tag {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.25rem 0.7rem;
  font-size: 0.75rem;
  color: var(--muted);
  transition: color 0.2s, border-color 0.2s;
}
.skill-tag:hover { color: var(--text); border-color: var(--accent2); }

/* ── PROJECTS ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.25rem;
}
.project-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: border-color 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.project-card:hover {
  border-color: rgba(123,140,255,0.4);
  transform: translateY(-3px);
}
.project-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.project-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}
.project-link {
  color: var(--accent2);
  text-decoration: none;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  border: 1px solid rgba(123,140,255,0.3);
  border-radius: 6px;
  padding: 0.2rem 0.6rem;
  transition: all 0.2s;
  white-space: nowrap;
}
.project-link:hover { background: rgba(123,140,255,0.1); }
.project-desc { color: var(--muted); font-size: 0.88rem; line-height: 1.65; }
.project-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.25rem; }
.project-tag {
  background: var(--bg3);
  border-radius: 4px;
  padding: 0.15rem 0.55rem;
  font-size: 0.7rem;
  color: var(--accent2);
  border: 1px solid rgba(123,140,255,0.2);
}

/* ── EDUCATION ── */
.edu-list { display: flex; flex-direction: column; gap: 1.25rem; }
.edu-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 1.5rem;
  padding: 1.5rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s;
}
.edu-item:hover { border-color: rgba(78,255,176,0.2); }
.edu-year {
  font-size: 0.8rem;
  color: var(--accent);
  letter-spacing: 0.05em;
  padding-top: 0.2rem;
}
.edu-title {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 0.25rem;
}
.edu-institution { color: var(--muted); font-size: 0.85rem; }

/* ── CONTACT ── */
#contact { text-align: center; }
.contact-desc {
  color: var(--muted);
  max-width: 460px;
  margin: 0 auto 2.5rem;
  font-size: 0.95rem;
}
.contact-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.contact-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--muted);
  text-decoration: none;
  font-size: 0.85rem;
  transition: all 0.2s;
}
.contact-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}
.contact-icon { font-size: 1rem; }

/* ── FOOTER ── */
footer {
  text-align: center;
  padding: 2rem;
  color: var(--muted);
  font-size: 0.75rem;
  border-top: 1px solid var(--border);
  letter-spacing: 0.05em;
}
footer span { color: var(--accent); }

/* ── LIGHT THEME ── */
[data-theme="light"] {
  --bg:     #f4f4f0;
  --bg2:    #eaeae5;
  --bg3:    #dfdfd8;
  --accent: #00875a;
  --accent2: #3a4fd4;
  --text:   #1a1d26;
  --muted:  #5a5f72;
  --border: rgba(0,0,0,0.1);
}
[data-theme="light"] nav {
  background: rgba(244,244,240,0.85);
}

/* ── THEME TOGGLE ── */
.theme-toggle {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.35rem 0.6rem;
  cursor: pointer;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1;
  transition: all 0.2s;
  flex-shrink: 0;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }

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

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  nav { padding: 1rem 1.25rem; }
  .nav-links { gap: 1.25rem; }
  #hero, section { padding-left: 1.25rem; padding-right: 1.25rem; }
  .edu-item { grid-template-columns: 1fr; gap: 0.5rem; }
}
