/* ============================================================
   ✨ CUSTOMIZE ME — change these variables to re-theme the site
   ============================================================ */
:root {
  --bg: #0a0e1a;             /* page background */
  --bg-soft: #101527;        /* cards / navbar */
  --bg-softer: #161d33;      /* hover states */
  --text: #e6e9f2;           /* main text */
  --text-dim: #9aa3ba;       /* secondary text */
  --accent-1: #7c5cff;       /* gradient start (violet) */
  --accent-2: #22d3ee;       /* gradient end (cyan) */
  --border: rgba(255, 255, 255, 0.08);
  --font-display: 'Sora', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius: 16px;
  --maxw: 1100px;
}

/* ============ RESET & BASE ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.7;
  overflow-x: hidden;
}
::selection { background: var(--accent-1); color: #fff; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.mono { font-family: var(--font-mono); }
.grad {
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.center { text-align: center; margin-top: 3rem; }

/* Scrollbar */
@supports not selector(::-webkit-scrollbar) {
  * { scrollbar-width: thin; scrollbar-color: rgba(124, 92, 255, 0.6) transparent; }
}
::-webkit-scrollbar { width: 13px; height: 13px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent-1), var(--accent-2));
  background-clip: padding-box;
  border: 3px solid transparent;
  min-height: 40px;
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #9b7bff, #4ae0f5);
  background-clip: padding-box;
}
::-webkit-scrollbar-corner { background: transparent; }

/* ============ BACKGROUND FX ============ */
.bg-grid {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
}
.bg-blob {
  position: fixed; z-index: -1; pointer-events: none;
  width: 480px; height: 480px; border-radius: 50%;
  filter: blur(120px); opacity: 0.16;
  animation: drift 24s ease-in-out infinite alternate;
}
.blob-1 { background: var(--accent-1); top: -10%; left: -8%; }
.blob-2 { background: var(--accent-2); bottom: -15%; right: -10%; animation-delay: -12s; }
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(80px, 60px) scale(1.15); }
}

/* ============ NAVBAR ============ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; gap: 2rem;
  padding: 1rem 2.5rem;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(10, 14, 26, 0.7);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.nav.scrolled { border-color: var(--border); box-shadow: 0 8px 32px rgba(0,0,0,0.35); }
.nav-logo {
  font-family: var(--font-mono); font-weight: 600; font-size: 1.15rem;
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.nav-links { display: flex; gap: 1.8rem; margin-left: auto; }
.nav-links a {
  font-size: 0.92rem; color: var(--text-dim); font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }
.nav-burger { display: none; background: none; border: 0; cursor: pointer; flex-direction: column; gap: 5px; padding: 6px; }
.nav-burger span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: 0.3s; }

/* ============ BUTTONS ============ */
.btn {
  display: inline-block; font-weight: 600; font-size: 0.95rem;
  padding: 0.8rem 1.7rem; border-radius: 12px; cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2));
  color: #fff;
  box-shadow: 0 8px 24px rgba(124, 92, 255, 0.35);
}
.btn-primary:hover { box-shadow: 0 12px 32px rgba(124, 92, 255, 0.5); }
.btn-outline {
  border: 1px solid var(--accent-1); color: var(--text);
  background: rgba(124, 92, 255, 0.06);
}
.btn-outline:hover { background: rgba(124, 92, 255, 0.15); }
.btn-sm { padding: 0.5rem 1.1rem; font-size: 0.85rem; }
.btn-lg { padding: 1rem 2.4rem; font-size: 1.05rem; }

/* ============ HERO ============ */
.hero {
  min-height: 100vh; max-width: var(--maxw); margin: 0 auto;
  padding: 8rem 2rem 4rem;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 3rem;
  align-items: center; position: relative;
}
.hero-kicker { color: var(--accent-2); font-size: 1rem; margin-bottom: 1rem; }
.hero-name {
  font-family: var(--font-display); font-size: clamp(2.6rem, 6vw, 4.2rem);
  font-weight: 800; line-height: 1.1; letter-spacing: -1px;
}
.hero-role {
  font-family: var(--font-display); font-size: clamp(1.3rem, 3vw, 1.9rem);
  font-weight: 600; color: var(--text-dim); margin: 0.8rem 0 1.4rem;
}
.typed { color: var(--text); }
.cursor { color: var(--accent-2); animation: blink 1s step-end infinite; font-weight: 400; }
@keyframes blink { 50% { opacity: 0; } }
.hero-blurb { max-width: 540px; color: var(--text-dim); font-size: 1.05rem; }
.hero-blurb strong { color: var(--text); }
.hero-actions { display: flex; gap: 1rem; margin: 2rem 0 1.8rem; flex-wrap: wrap; }
.socials { display: flex; gap: 1.1rem; }
.socials a {
  color: var(--text-dim); padding: 0.55rem;
  border: 1px solid var(--border); border-radius: 10px;
  display: inline-flex; transition: 0.25s;
}
.socials a:hover { color: var(--accent-2); border-color: var(--accent-2); transform: translateY(-3px); }

/* Hero code card */
.code-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.4rem 1.6rem;
  box-shadow: 0 24px 64px rgba(0,0,0,0.45);
  transform: rotate(2deg);
  transition: transform 0.4s;
}
.code-card:hover { transform: rotate(0deg) scale(1.02); }
.code-dots { display: flex; gap: 7px; margin-bottom: 1rem; }
.code-dots i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.code-dots i:nth-child(2) { background: #febc2e; }
.code-dots i:nth-child(3) { background: #28c840; }
.code-card pre { overflow-x: auto; font-size: 0.86rem; line-height: 1.8; }
.c-key { color: #c792ea; }
.c-var { color: #82aaff; }
.c-prop { color: #7fdbca; }
.c-str { color: #ecc48d; }

.scroll-hint {
  position: absolute; bottom: 2.2rem; left: 50%; transform: translateX(-50%);
  width: 26px; height: 42px; border: 2px solid var(--text-dim); border-radius: 14px;
}
.scroll-hint span {
  position: absolute; top: 7px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 8px; border-radius: 2px; background: var(--accent-2);
  animation: scrolldot 1.8s ease-in-out infinite;
}
@keyframes scrolldot { 0% { opacity: 1; top: 7px; } 70% { opacity: 0; top: 22px; } 100% { opacity: 0; } }

/* ============ STATS ============ */
.stats {
  max-width: var(--maxw); margin: 0 auto; padding: 2rem;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem;
}
.stat {
  text-align: center; padding: 1.8rem 1rem;
  background: var(--bg-soft); border: 1px solid var(--border); border-radius: var(--radius);
  transition: transform 0.25s, border-color 0.25s;
}
.stat:hover { transform: translateY(-4px); border-color: var(--accent-1); }
.stat-num { display: block; font-family: var(--font-display); font-size: 2.4rem; font-weight: 800; }
.stat-label { color: var(--text-dim); font-size: 0.88rem; }

/* ============ SECTIONS ============ */
.section { max-width: var(--maxw); margin: 0 auto; padding: 6rem 2rem 2rem; }
.section-title {
  font-family: var(--font-display); font-size: clamp(1.7rem, 4vw, 2.2rem);
  font-weight: 700; margin-bottom: 3rem;
  display: flex; align-items: center; gap: 0.8rem;
}
.section-index { color: var(--accent-2); font-size: 1.2rem; font-weight: 400; }
.section-title::after {
  content: ''; flex: 1; height: 1px; max-width: 300px;
  background: linear-gradient(90deg, var(--border), transparent);
  margin-left: 1rem;
}

/* ============ ABOUT ============ */
.about-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 3.5rem; align-items: start; }
.about-text p { margin-bottom: 1.2rem; color: var(--text-dim); }
.about-text strong { color: var(--text); }
.about-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.6rem; text-align: center;
}
.avatar {
  width: 160px; height: 160px; border-radius: 50%; margin: 0 auto 1.4rem;
  border: 3px solid transparent;
  background: linear-gradient(var(--bg-soft), var(--bg-soft)) padding-box,
              linear-gradient(120deg, var(--accent-1), var(--accent-2)) border-box;
}
.about-facts { text-align: left; font-size: 0.85rem; color: var(--text-dim); display: grid; gap: 0.7rem; }
.about-facts span { margin-right: 0.5rem; }

/* ============ TIMELINE ============ */
.timeline { position: relative; padding-left: 2rem; }
.timeline::before {
  content: ''; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px;
  background: linear-gradient(180deg, var(--accent-1), var(--accent-2), transparent);
}
.tl-item { position: relative; margin-bottom: 2.5rem; }
.tl-dot {
  position: absolute; left: -2rem; top: 8px; width: 16px; height: 16px;
  border-radius: 50%; background: var(--bg);
  border: 3px solid var(--accent-2);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.15);
}
.tl-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.8rem 2rem;
  transition: transform 0.25s, border-color 0.25s;
}
.tl-card:hover { transform: translateX(6px); border-color: var(--accent-1); }
.tl-head { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
.tl-head h3 { font-family: var(--font-display); font-size: 1.15rem; font-weight: 700; }
.tl-company { color: var(--accent-2); }
.tl-date { font-size: 0.8rem; color: var(--text-dim); }
.tl-card ul { list-style: none; display: grid; gap: 0.6rem; margin-bottom: 1.2rem; }
.tl-card li { color: var(--text-dim); padding-left: 1.4rem; position: relative; font-size: 0.95rem; }
.tl-card li::before { content: '▹'; position: absolute; left: 0; color: var(--accent-2); }
.tl-card li strong { color: var(--text); }

/* ============ TAGS ============ */
.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tags span {
  font-family: var(--font-mono); font-size: 0.74rem;
  padding: 0.3rem 0.75rem; border-radius: 999px;
  background: rgba(124, 92, 255, 0.1); color: var(--accent-2);
  border: 1px solid rgba(124, 92, 255, 0.25);
}
.tags.lg span { font-size: 0.82rem; padding: 0.42rem 0.95rem; }

/* ============ SKILLS ============ */
.skills-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.skill-group {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.6rem 1.8rem;
  transition: transform 0.25s, border-color 0.25s;
}
.skill-group:hover { transform: translateY(-4px); border-color: var(--accent-1); }
.skill-group h3 { font-family: var(--font-display); font-size: 1.02rem; margin-bottom: 1rem; }

/* ============ PROJECTS ============ */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); gap: 1.5rem; }
.project-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.8rem;
  display: flex; flex-direction: column; gap: 0.8rem;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.project-card:hover {
  transform: translateY(-6px); border-color: var(--accent-1);
  box-shadow: 0 20px 48px rgba(0,0,0,0.4);
}
.project-top { display: flex; justify-content: space-between; align-items: center; }
.project-icon { font-size: 2rem; }
.project-links a {
  font-size: 1.3rem; color: var(--text-dim); transition: 0.2s;
  padding: 0.2rem 0.5rem; border-radius: 8px;
}
.project-links a:hover { color: var(--accent-2); background: var(--bg-softer); }
.project-card h3 { font-family: var(--font-display); font-size: 1.2rem; font-weight: 700; }
.project-card p { color: var(--text-dim); font-size: 0.92rem; flex: 1; }

/* ============ ACHIEVEMENTS ============ */
.achievements-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }
.ach-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.8rem; text-align: center;
  transition: transform 0.25s, border-color 0.25s;
}
.ach-card:hover { transform: translateY(-4px); border-color: var(--accent-2); }
.ach-icon { font-size: 2.2rem; display: block; margin-bottom: 0.8rem; }
.ach-card h3 { font-family: var(--font-display); font-size: 1.05rem; margin-bottom: 0.4rem; }
.ach-card p { color: var(--text-dim); font-size: 0.88rem; }

/* ============ CONTACT ============ */
.contact { text-align: center; padding-bottom: 6rem; }
.contact-kicker { font-size: 1rem; margin-bottom: 1rem; }
.contact-title { font-family: var(--font-display); font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; margin-bottom: 1.2rem; }
.contact-blurb { color: var(--text-dim); max-width: 520px; margin: 0 auto 2.4rem; }
.contact-meta { margin-top: 2.2rem; color: var(--text-dim); font-size: 0.85rem; display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.contact-meta a:hover { color: var(--accent-2); }

/* ============ FOOTER ============ */
.footer { text-align: center; padding: 2.4rem 1rem; border-top: 1px solid var(--border); font-size: 0.82rem; color: var(--text-dim); }
.footer-sub { margin-top: 0.3rem; font-size: 0.75rem; opacity: 0.7; }

/* ============ SCROLL REVEAL ============ */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ============ RESPONSIVE ============ */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 7rem; text-align: left; }
  .hero-visual { display: none; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: 1fr; }
  .about-card { max-width: 340px; margin: 0 auto; }
}
@media (max-width: 700px) {
  .nav { padding: 0.9rem 1.2rem; gap: 1rem; }
  .nav-links {
    position: fixed; top: 60px; right: 0; flex-direction: column;
    background: var(--bg-soft); border: 1px solid var(--border);
    border-radius: 0 0 0 var(--radius);
    padding: 1.5rem 2.5rem; gap: 1.2rem;
    transform: translateX(110%); transition: transform 0.3s;
  }
  .nav-links.open { transform: translateX(0); }
  .nav-burger { display: flex; margin-left: auto; }
  .nav > .btn { display: none; }
  .section { padding: 4rem 1.3rem 1rem; }
  .stats { grid-template-columns: repeat(2, 1fr); padding: 1.3rem; }
  .timeline { padding-left: 1.6rem; }
  .tl-dot { left: -1.6rem; }
}
