:root {
  --bg: #080b14;
  --surface: rgba(16, 21, 36, 0.72);
  --surface-solid: #101524;
  --text: #f5f7fb;
  --muted: #a8b0c3;
  --line: rgba(255,255,255,.10);
  --accent: #8b7cff;
  --accent-2: #52d6c9;
  --shadow: 0 24px 80px rgba(0,0,0,.30);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

.progress-bar {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  z-index: 9999;
}

.background-grid {
  position: fixed; inset: 0; pointer-events: none; opacity: .20;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: linear-gradient(to bottom, black, transparent 75%);
}

.orb {
  position: fixed; width: 420px; height: 420px; border-radius: 50%;
  filter: blur(90px); opacity: .16; pointer-events: none; z-index: -1;
}
.orb-one { background: var(--accent); top: -160px; right: -120px; }
.orb-two { background: var(--accent-2); bottom: -180px; left: -160px; }

.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 6vw; background: rgba(8,11,20,.70);
  backdrop-filter: blur(18px); border-bottom: 1px solid transparent;
  transition: .3s ease;
}
.navbar.scrolled { border-color: var(--line); }
.brand { font: 700 1.5rem "Space Grotesk", sans-serif; letter-spacing: -.04em; }
.brand span { color: var(--accent); }
nav { display: flex; gap: 26px; }
nav a { color: var(--muted); font-size: .88rem; transition: .25s ease; }
nav a:hover, nav a.active { color: var(--text); }

.menu-toggle { display: none; background: none; color: white; border: 0; font-size: 1.5rem; cursor: pointer; }

.section { width: min(1160px, 88vw); margin: 0 auto; padding: 110px 0; }

.hero {
  min-height: 100vh; display: grid; grid-template-columns: 1.15fr .85fr;
  gap: 60px; align-items: center; padding-top: 150px;
}

.eyebrow {
  color: var(--accent-2); font-size: .75rem; font-weight: 700;
  letter-spacing: .16em; margin-bottom: 18px;
}

h1, h2, h3 { font-family: "Space Grotesk", sans-serif; line-height: 1.1; }
h1 { font-size: clamp(3.2rem, 7vw, 6.5rem); letter-spacing: -.065em; }
h1 span {
  background: linear-gradient(100deg, #fff 20%, var(--accent) 60%, var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero h2 { margin-top: 24px; max-width: 780px; font-size: clamp(1.15rem, 2vw, 1.55rem); color: #d8dced; font-weight: 600; }
.hero-subtitle { margin-top: 15px; color: var(--accent-2); font-weight: 600; }
.hero-text { margin-top: 20px; max-width: 720px; color: var(--muted); font-size: 1rem; }

.hero-actions { display: flex; gap: 14px; margin-top: 30px; flex-wrap: wrap; }
.btn {
  padding: 13px 20px; border-radius: 999px; border: 1px solid var(--line);
  font-weight: 700; transition: .25s ease;
}
.btn-primary { background: var(--text); color: var(--bg); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 14px 35px rgba(255,255,255,.12); }
.btn-secondary:hover { background: rgba(255,255,255,.07); transform: translateY(-3px); }

.social-links { display: flex; gap: 18px; margin-top: 24px; color: var(--muted); font-size: .9rem; }
.social-links a:hover { color: var(--accent-2); }

.hero-visual { display: flex; justify-content: center; }
.profile-wrap { position: relative; width: min(430px, 80vw); aspect-ratio: 1; }
.profile-ring {
  position: absolute; inset: -18px; border: 1px solid rgba(139,124,255,.45);
  border-radius: 50%; animation: spin 18s linear infinite;
}
.profile-ring::after {
  content: ""; position: absolute; width: 12px; height: 12px; border-radius: 50%;
  background: var(--accent-2); top: 12%; right: 13%; box-shadow: 0 0 25px var(--accent-2);
}
.profile-photo {
  width: 100%; height: 100%; object-fit: cover; border-radius: 50%;
  border: 8px solid rgba(255,255,255,.08); box-shadow: var(--shadow);
}
.floating-card {
  position: absolute; padding: 10px 15px; border: 1px solid var(--line);
  background: rgba(12,16,28,.78); backdrop-filter: blur(12px);
  border-radius: 14px; box-shadow: var(--shadow); font-size: .8rem; font-weight: 700;
  animation: float 4s ease-in-out infinite;
}
.card-ai { top: 12%; left: -8%; }
.card-python { right: -5%; top: 45%; animation-delay: 1s; }
.card-cloud { left: 2%; bottom: 8%; animation-delay: 2s; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); margin-right: 7px; }

.section-heading { max-width: 760px; margin-bottom: 48px; }
.section-heading h2 { font-size: clamp(2rem, 4vw, 3.5rem); letter-spacing: -.045em; }

.about-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 24px; }
.glass-card, .skill-card, .project-card, .cert-group, .education-card {
  background: var(--surface); border: 1px solid var(--line); backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}
.glass-card { padding: 34px; border-radius: 26px; color: var(--muted); }
.glass-card p + p { margin-top: 18px; }
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.stat-card {
  padding: 28px; border: 1px solid var(--line); border-radius: 22px;
  background: rgba(255,255,255,.035); display: flex; flex-direction: column;
}
.stat-card strong { font: 700 2rem "Space Grotesk"; }
.stat-card span { color: var(--muted); font-size: .85rem; margin-top: 4px; }

.skills-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; }
.skill-card { border-radius: 20px; padding: 24px; transition: .3s ease; }
.skill-card:hover, .project-card:hover { transform: translateY(-8px); border-color: rgba(139,124,255,.45); }
.skill-icon {
  width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(139,124,255,.13); color: var(--accent-2); font-weight: 800; margin-bottom: 18px;
}
.skill-card h3 { font-size: 1.1rem; }
.skill-card p { color: var(--muted); font-size: .88rem; margin-top: 8px; }

.projects-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.project-card { position: relative; border-radius: 24px; padding: 30px; overflow: hidden; transition: .3s ease; }
.project-card.featured { grid-column: span 2; background: linear-gradient(135deg, rgba(139,124,255,.16), rgba(82,214,201,.06)); }
.project-number { color: rgba(255,255,255,.28); font: 700 2.4rem "Space Grotesk"; position: absolute; right: 22px; top: 18px; }
.project-tag, .timeline-label { color: var(--accent-2); font-size: .7rem; font-weight: 800; letter-spacing: .12em; }
.project-card h3 { margin-top: 10px; font-size: 1.45rem; }
.project-card p { color: var(--muted); margin-top: 12px; max-width: 700px; }
.tech-list { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.tech-list span {
  padding: 6px 10px; border-radius: 999px; background: rgba(255,255,255,.06);
  color: #c9cede; font-size: .72rem;
}

.timeline { border-left: 1px solid var(--line); margin-left: 8px; padding-left: 32px; }
.timeline-item { position: relative; margin-bottom: 22px; }
.timeline-dot {
  position: absolute; left: -39px; top: 5px; width: 13px; height: 13px;
  border-radius: 50%; background: var(--accent); box-shadow: 0 0 20px rgba(139,124,255,.65);
}
.timeline-content {
  padding: 30px; border-radius: 24px; background: var(--surface);
  border: 1px solid var(--line);
}
.timeline-content h3 { margin-top: 9px; font-size: 1.6rem; }
.timeline-content p { color: var(--muted); margin-top: 10px; }

.cert-groups { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cert-group { padding: 30px; border-radius: 24px; }
.cert-group h3 { font-size: 1.4rem; margin-bottom: 18px; }
.cert-group ul { list-style: none; }
.cert-group li { padding: 12px 0 12px 22px; color: var(--muted); border-bottom: 1px solid var(--line); position: relative; }
.cert-group li:last-child { border-bottom: 0; }
.cert-group li::before { content: "✦"; color: var(--accent-2); position: absolute; left: 0; }

.education-card {
  padding: 34px; border-radius: 26px; display: flex; justify-content: space-between; gap: 30px; align-items: center;
}
.education-card h3 { margin-top: 8px; font-size: 2rem; }
.education-card p { color: var(--muted); margin-top: 5px; }
.education-meta { display: flex; flex-direction: column; align-items: flex-end; }
.education-meta strong { font: 700 2.5rem "Space Grotesk"; color: var(--accent-2); }
.education-meta span { color: var(--muted); font-size: .8rem; }

.contact-section { padding-bottom: 120px; }
.contact-card {
  text-align: center; padding: 70px 30px; border-radius: 32px;
  border: 1px solid var(--line);
  background: radial-gradient(circle at top, rgba(139,124,255,.18), transparent 60%), var(--surface);
}
.contact-card h2 { font-size: clamp(2rem, 5vw, 4rem); max-width: 800px; margin: auto; letter-spacing: -.05em; }
.contact-card > p:not(.eyebrow):not(.email-display) { color: var(--muted); max-width: 650px; margin: 18px auto 0; }
.contact-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.contact-link { padding: 12px 18px; border: 1px solid var(--line); border-radius: 999px; transition: .25s ease; }
.contact-link:hover { transform: translateY(-3px); background: rgba(255,255,255,.07); }
.contact-link.primary { background: var(--text); color: var(--bg); }
.email-display { margin-top: 24px; color: var(--accent-2); font-weight: 700; }

footer { border-top: 1px solid var(--line); padding: 30px 6vw; color: var(--muted); text-align: center; font-size: .8rem; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .75s ease, transform .75s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero-text { margin-left: auto; margin-right: auto; }
  .hero-actions, .social-links { justify-content: center; }
  .hero-visual { order: -1; }
  .profile-wrap { width: min(330px, 70vw); }
  .skills-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid, .cert-groups { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .navbar { padding: 17px 6vw; }
  .menu-toggle { display: block; }
  nav {
    position: absolute; top: 70px; left: 5vw; right: 5vw; display: none;
    flex-direction: column; padding: 20px; border-radius: 18px;
    background: rgba(12,16,28,.96); border: 1px solid var(--line);
  }
  nav.open { display: flex; }
  .section { padding: 80px 0; }
  .hero { padding-top: 125px; }
  .skills-grid, .projects-grid { grid-template-columns: 1fr; }
  .project-card.featured { grid-column: auto; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .education-card { flex-direction: column; align-items: flex-start; }
  .education-meta { align-items: flex-start; }
  h1 { font-size: clamp(2.7rem, 14vw, 4.3rem); }
  .floating-card { display: none; }
}
