:root{
  --bg: #070a12;
  --bg-soft: #0b1020;
  --surface: rgba(255,255,255,0.045);
  --surface2: rgba(255,255,255,0.08);
  --text: rgba(255,255,255,0.94);
  --muted: rgba(255,255,255,0.62);
  --line: rgba(255,255,255,0.10);
  --accent: #10b981;
  --accent2: #22d3ee;
  --accent-ink: #04130d;
  --accent-soft: rgba(16,185,129,0.14);
  --ring: rgba(16,185,129,0.40);
  --shadow: 0 24px 64px rgba(0,0,0,0.50);
  --shadow-accent: 0 18px 44px rgba(16,185,129,0.20);
  --radius: 16px;
  --radius2: 22px;
  --max: 1140px;
  --grad: linear-gradient(135deg, var(--accent), var(--accent2));
}

[data-theme="light"]{
  --bg: #f6f8fc;
  --bg-soft: #eef2f9;
  --surface: rgba(8,15,40,0.04);
  --surface2: rgba(8,15,40,0.07);
  --text: rgba(8,12,20,0.90);
  --muted: rgba(8,12,20,0.56);
  --line: rgba(8,15,40,0.10);
  --accent: #059669;
  --accent2: #0891b2;
  --accent-ink: #ffffff;
  --accent-soft: rgba(5,150,105,0.12);
  --ring: rgba(5,150,105,0.32);
  --shadow: 0 18px 44px rgba(8,15,40,0.12);
  --shadow-accent: 0 14px 34px rgba(5,150,105,0.18);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  overflow-x: hidden;
  background:
    radial-gradient(1200px 640px at 50% -12%, var(--accent-soft), transparent 60%),
    radial-gradient(900px 520px at 92% 6%, rgba(34,211,238,0.10), transparent 55%),
    var(--bg);
  background-attachment: fixed;
}

/* Ambient background */
.bg{ position: fixed; inset: 0; z-index: -1; overflow:hidden; }
.blob{
  position:absolute;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.34;
  transform: translate3d(0,0,0);
  animation: float 11s ease-in-out infinite;
}
.b1{ left:-160px; top:-160px; background: var(--accent); }
.b2{ right:-180px; bottom:-180px; background: var(--accent2); animation-delay: 1.4s; }

.grid{
  position:absolute; inset:0;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 88px 88px;
  opacity: 0.12;
  mask-image: radial-gradient(circle at 50% 14%, black 0%, transparent 60%);
}

@keyframes float{
  0%,100%{ transform: translate(0,0) scale(1); }
  50%{ transform: translate(24px, -20px) scale(1.04); }
}

/* Layout */
.container{ max-width: var(--max); margin: 0 auto; padding: 104px 20px 40px; }

.header{
  position: sticky; top:0; z-index:10;
  display:flex; align-items:center; justify-content:space-between;
  padding: 14px 20px;
  backdrop-filter: blur(16px);
  background: color-mix(in oklab, var(--bg), transparent 28%);
  border-bottom: 1px solid var(--line);
}

.brand{
  width: 44px; height: 44px;
  display:grid; place-items:center;
  border-radius: 14px;
  background: var(--grad);
  color: var(--accent-ink);
  text-decoration:none;
  font-weight: 900;
  letter-spacing: -0.02em;
  box-shadow: var(--shadow-accent);
}

.nav{ display:flex; gap: 6px; }
.nav a{
  color: var(--muted);
  text-decoration:none;
  font-weight:700;
  padding: 10px 12px;
  border-radius: 12px;
  transition: 180ms ease;
}
.nav a:hover{ color: var(--text); background: var(--surface); }

.iconBtn{
  width: 44px; height: 44px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  cursor:pointer;
  transition: 180ms ease;
}
.iconBtn:hover{ transform: translateY(-1px); background: var(--surface2); border-color: var(--ring); }

.section{ padding: 56px 0; }
.sectionHead{ margin-bottom: 6px; }
.sectionHead h2{
  margin: 0 0 8px;
  font-size: clamp(24px, 3.4vw, 32px);
  letter-spacing: -0.025em;
  font-weight: 900;
  display:inline-flex; align-items:center; gap:12px;
}
.sectionHead h2::before{
  content:"";
  width: 26px; height: 3px;
  border-radius: 999px;
  background: var(--grad);
}
.sectionHead p{ margin: 0; color: var(--muted); }

/* Hero */
.hero{
  display:grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 26px;
  padding: 18px 0 8px;
  align-items: center;
}
@media (max-width: 920px){
  .hero{ grid-template-columns: 1fr; }
  .nav{ display:none; }
}

.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  background: var(--accent-soft);
  border:1px solid var(--ring);
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--text);
  font-weight: 700;
  font-size: 13px;
  width: fit-content;
}

h1{
  margin: 16px 0 10px;
  font-size: clamp(40px, 6vw, 62px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 900;
}

.sub{
  margin: 0 0 24px;
  color: var(--muted);
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.6;
  min-height: 28px;
}
.typing{
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 800;
}

.ctaRow{ display:flex; gap: 12px; flex-wrap: wrap; }
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  padding: 13px 18px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  text-decoration:none;
  font-weight: 800;
  transition: 180ms ease;
}
.btn:hover{ transform: translateY(-2px); background: var(--surface2); border-color: var(--ring); }

.btn.primary{
  background: var(--grad);
  border-color: transparent;
  color: var(--accent-ink);
  box-shadow: var(--shadow-accent);
}
.btn.primary:hover{ filter: brightness(1.05); }

.miniStats{
  margin-top: 26px;
  display:flex; gap: 12px; flex-wrap: wrap;
}
.stat{
  min-width: 132px;
  padding: 14px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
}
.statNum{
  font-size: 24px; font-weight: 900;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.statLbl{ color: var(--muted); font-weight: 700; margin-top: 2px; font-size: 13px; }

/* Cards */
.card{
  border-radius: var(--radius2);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 20px;
  position: relative;
  overflow:hidden;
  transition: 200ms ease;
}
.card::after{
  content:"";
  position:absolute; inset:0;
  background: radial-gradient(120% 80% at 50% -10%, var(--accent-soft), transparent 55%);
  pointer-events:none;
}

.profileCard{
  display:grid;
  grid-template-columns: 132px 1fr;
  gap: 16px;
  align-items:start;
}
@media (max-width: 520px){
  .profileCard{ grid-template-columns: 1fr; }
}

.avatar{
  width: 132px;
  height: 132px;
  border-radius: 20px;
  border: 1px solid var(--ring);
  background: var(--surface2);
  overflow:hidden;
  box-shadow: var(--shadow-accent);
}
.avatar img{ width:100%; height:100%; object-fit: cover; display:block; }

.profileText h3{ margin: 0 0 8px; font-size: 18px; }
.profileText p{ margin: 0 0 14px; color: var(--muted); line-height: 1.7; }

.chips{ display:flex; flex-wrap:wrap; gap: 8px; }
.chip{
  padding: 7px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-weight: 700;
  font-size: 12px;
  transition: 160ms ease;
}
.chip:hover{ color: var(--text); border-color: var(--ring); }

.grid2{
  margin-top: 18px;
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 820px){
  .grid2{ grid-template-columns: 1fr; }
}

.cards3{
  margin-top: 18px;
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 980px){
  .cards3{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px){
  .cards3{ grid-template-columns: 1fr; }
}

.card h3{ font-size: 17px; }
.list{ margin: 10px 0 0; padding-left: 18px; color: var(--muted); line-height: 1.8; }
.hr{ height:1px; background: var(--line); margin: 16px 0; }

.muted{ color: var(--muted); line-height: 1.7; }

.eduTop{ display:flex; justify-content:space-between; gap: 10px; align-items:baseline; }
.eduSchool{ font-weight: 900; letter-spacing: -0.01em; }
.eduYear{ color: var(--muted); font-weight: 800; }

.toolbar{
  display:flex; gap: 12px; flex-wrap: wrap;
  margin-top: 16px;
}
.input, .select{
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  outline: none;
  font-weight: 700;
  transition: 160ms ease;
}
.input::placeholder{ color: var(--muted); font-weight: 600; }
.input:focus, .select:focus{ border-color: var(--ring); box-shadow: 0 0 0 3px var(--accent-soft); }
.input{ flex: 1; min-width: 240px; }
.select{ min-width: 180px; cursor:pointer; }

.projectCard{ transition: 200ms ease; }
.projectCard:hover{
  transform: translateY(-4px);
  background: var(--surface2);
  border-color: var(--ring);
}

.projectName{
  margin: 0;
  font-size: 16px;
  letter-spacing: -0.01em;
  font-weight: 900;
}
.projectDesc{
  margin: 10px 0 12px;
  color: var(--muted);
  line-height: 1.65;
  min-height: 44px;
}
.badges{ display:flex; gap: 8px; flex-wrap:wrap; }
.badge{
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.projectLinks{ display:flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.linkBtn{
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  text-decoration:none;
  font-weight: 800;
  transition: 180ms ease;
}
.linkBtn:hover{ transform: translateY(-2px); background: var(--surface2); border-color: var(--ring); }

.note{
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: var(--radius2);
  border: 1px dashed var(--ring);
  color: var(--muted);
  background: var(--accent-soft);
  display:flex; gap: 12px; align-items:flex-start;
}
.dot{
  width: 10px; height: 10px;
  border-radius: 50%;
  margin-top: 6px;
  background: var(--grad);
}

.links{ display:flex; gap: 10px; flex-wrap: wrap; }

.details summary{
  cursor:pointer;
  font-weight: 900;
  color: var(--text);
}
.details p{ margin:0; }

/* Footer */
.footer{
  padding: 30px 0 8px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  text-align:center;
}

/* Reveal animation */
.reveal{
  opacity: 0;
  transform: translateY(12px);
  transition: 640ms cubic-bezier(.2,.8,.2,1);
  transition-delay: var(--d, 0s);
}
.reveal.in{
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce){
  .blob{ animation: none; }
  .reveal{ transition: none; opacity:1; transform:none; }
}
