:root {
  color-scheme: dark;
  --bg: #04070c;
  --bg-soft: rgba(255, 255, 255, 0.05);
  --stroke: rgba(255, 255, 255, 0.14);
  --text: #f3f4f6;
  --muted: #a5b4fc;
  --accent: #7dd3fc;
  --accent-strong: #60a5fa;
  --accent-2: #fb7185;
  --shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(125, 211, 252, 0.18), transparent 24%),
    radial-gradient(circle at 90% 10%, rgba(251, 113, 133, 0.16), transparent 22%),
    linear-gradient(135deg, #04070c 0%, #0b1020 45%, #060811 100%);
  overflow-x: hidden;
  min-height: 100vh;
}
body::before,
body::after {
  content: '';
  position: fixed;
  inset: auto;
  width: 32rem;
  height: 32rem;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.24;
  pointer-events: none;
  animation: drift 18s ease-in-out infinite alternate;
}
body::before { top: -10rem; left: -10rem; background: var(--accent); }
body::after { right: -10rem; bottom: -10rem; background: var(--accent-2); animation-delay: 3s; }

::selection { background: rgba(125, 211, 252, 0.3); color: white; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { width: min(1160px, calc(100% - 2rem)); margin: 0 auto; }
section { position: relative; padding: 5rem 0; }

#scroll-progress {
  position: fixed;
  inset: 0 auto auto 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  z-index: 50;
}

.cursor {
  position: fixed;
  width: 25px;
  height: 25px;
  border: 1px solid rgba(125, 211, 252, 0.8);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 100;
  transition: width 0.2s ease, height 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
  mix-blend-mode: difference;
}
.cursor.active { width: 42px; height: 42px; border-color: #fff; }

.loading-screen {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(4, 7, 12, 0.94);
  z-index: 80;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}
.loading-screen.hidden { opacity: 0; visibility: hidden; }
.loader {
  width: 68px; height: 68px; border-radius: 50%;
  border: 3px solid rgba(255,255,255,0.15); border-top-color: var(--accent); animation: spin 1s linear infinite;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: rgba(7, 11, 20, 0.65);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.navbar {
  width: min(1160px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1rem 0;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand {
  font-weight: 800; letter-spacing: 0.24em; font-size: 0.95rem; color: white;
}
.site-nav { display: flex; gap: 1.25rem; align-items: center; }
.site-nav a { color: #d7e2ef; font-size: 0.95rem; transition: color 0.2s ease; }
.site-nav a:hover, .site-nav a.active { color: var(--accent); }
.nav-actions { display: flex; align-items: center; gap: 0.8rem; }
.resume-pill, .menu-toggle {
  border: 1px solid rgba(255,255,255,0.14); background: rgba(255,255,255,0.06); color: white; padding: 0.7rem 1rem; border-radius: 999px; cursor: pointer;
}
.resume-pill:hover { transform: translateY(-2px); }
.menu-toggle { display: none; }

.hero {
  padding: 5rem 0 4rem;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2.8rem; align-items: center;
}
.eyebrow {
  display: inline-block; margin: 0 0 0.85rem; color: var(--accent); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.3em; text-transform: uppercase;
}
.hero h1 { font-size: clamp(2.2rem, 4vw, 3.6rem); line-height: 1.08; margin: 0 0 1rem; }
.hero h1 .accent { color: var(--accent); }
.hero p { color: #ced7e4; line-height: 1.8; margin: 0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin: 1.6rem 0 1.35rem; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; padding: 0.9rem 1.2rem; border-radius: 999px; border: 1px solid transparent; font-weight: 600; transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong)); color: #03111f; box-shadow: 0 12px 30px rgba(96, 165, 250, 0.25);
}
.btn-secondary {
  background: rgba(255, 255, 255, 0.05); border-color: rgba(255,255,255,0.14); color: white;
}
.social-links { display: flex; gap: 0.8rem; margin-top: 1rem; }
.social-links a {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(255,255,255,0.12); background: rgba(255,255,255,0.06); color: white; transition: transform 0.2s ease, border-color 0.2s ease;
}
.social-links a:hover { transform: translateY(-3px); border-color: var(--accent); }

.hero-visual { position: relative; min-height: 420px; }
.profile-shell {
  position: relative; width: min(360px, 100%); margin: 0 auto; padding: 1rem; border-radius: 2rem; background: linear-gradient(135deg, rgba(255,255,255,0.12), rgba(255,255,255,0.02)); border: 1px solid rgba(255,255,255,0.16); box-shadow: var(--shadow); backdrop-filter: blur(24px);
}
.profile-shell::before {
  content: ''; position: absolute; inset: -12px; border-radius: 2rem; border: 1px solid rgba(125,211,252,0.35); animation: pulseRing 3s ease-in-out infinite;
}
.profile-shell img { width: 100%; height: 420px; object-fit: cover; border-radius: 1.5rem; }
.floating-card {
  position: absolute; right: -0.3rem; bottom: -0.8rem; max-width: 220px; padding: 1rem 1.1rem; border-radius: 1rem; background: rgba(8, 13, 24, 0.92); border: 1px solid rgba(255,255,255,0.13); box-shadow: var(--shadow);
}
.floating-card strong { display: block; margin-bottom: 0.35rem; }
.orb {
  position: absolute; border-radius: 50%; background: linear-gradient(135deg, rgba(125, 211, 252, 0.35), rgba(251, 113, 133, 0.22)); filter: blur(6px); animation: float 6s ease-in-out infinite;
}
.orb.one { width: 120px; height: 120px; top: 8%; left: -2rem; }
.orb.two { width: 90px; height: 90px; bottom: 10%; right: 6%; animation-delay: 1.2s; }
.orb.three { width: 70px; height: 70px; left: 8%; bottom: 7%; animation-delay: 2s; }

.glass-card, .timeline-item, .skill-card, .project-card, .cert-card, .contact-card, .stat-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.10), rgba(255,255,255,0.04)); border: 1px solid rgba(255,255,255,0.12); box-shadow: var(--shadow); backdrop-filter: blur(16px);
}
.section-title { margin-bottom: 1.6rem; }
.section-title h2 { font-size: clamp(1.5rem, 2.2vw, 2rem); margin: 0 0 0.5rem; }
.section-title p { color: #cbd5e1; line-height: 1.7; margin: 0; }

.about-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 1.2rem; align-items: start; }
.about-card { padding: 1.6rem; border-radius: 1.4rem; }
.about-card p { color: #dbe4ee; line-height: 1.8; }
.stats-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.stat-card { padding: 1.1rem; border-radius: 1.2rem; text-align: center; transition: transform 0.2s ease, border-color 0.2s ease; }
.stat-card:hover { transform: translateY(-3px); border-color: var(--accent); }
.stat-card strong { display: block; font-size: 1.4rem; margin-bottom: 0.3rem; color: white; }
.stat-card span { color: #cbd5e1; font-size: 0.95rem; }

.skills-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.skill-card { padding: 1.2rem; border-radius: 1.2rem; transition: transform 0.2s ease, border-color 0.2s ease; }
.skill-card:hover { transform: translateY(-4px); border-color: var(--accent); }
.skill-card .icon { font-size: 1.35rem; margin-bottom: 0.8rem; }
.skill-card h3 { margin: 0 0 0.4rem; font-size: 1.05rem; }
.skill-card ul { margin: 0.6rem 0 0; padding-left: 1rem; color: #dfe7ef; line-height: 1.7; font-size: 0.95rem; }

.projects-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.project-card { border-radius: 1.3rem; overflow: hidden; transition: transform 0.2s ease, border-color 0.2s ease; }
.project-card:hover { transform: translateY(-4px); border-color: var(--accent); }
.project-card img { height: 220px; width: 100%; object-fit: cover; transition: transform 0.5s ease; }
.project-card:hover img { transform: scale(1.05); }
.project-body { padding: 1rem 1rem 1.15rem; }
.badges { display: flex; gap: 0.45rem; flex-wrap: wrap; margin: 0.6rem 0 0.8rem; }
.badges span { background: rgba(125,211,252,0.16); color: var(--accent); padding: 0.35rem 0.6rem; border-radius: 999px; font-size: 0.76rem; }
.project-links { display: flex; gap: 0.7rem; margin-top: 0.8rem; }
.project-links a { display: inline-flex; align-items: center; justify-content: center; padding: 0.7rem 0.95rem; border-radius: 999px; font-size: 0.9rem; border: 1px solid rgba(255,255,255,0.14); background: rgba(255,255,255,0.05); }
.project-links a:hover { border-color: var(--accent); color: var(--accent); }

.timeline { display: grid; gap: 1rem; }
.timeline-item { padding: 1.2rem 1.3rem; border-radius: 1.2rem; }
.timeline-item .topline { display: flex; justify-content: space-between; gap: 0.7rem; align-items: center; margin-bottom: 0.5rem; }
.timeline-item h3 { margin: 0; font-size: 1.05rem; }
.timeline-item .meta { color: var(--accent); font-size: 0.9rem; }
.timeline-item p, .timeline-item li { color: #dbe4ee; line-height: 1.7; }
.timeline-item ul { padding-left: 1rem; margin: 0.4rem 0 0; }

.certificate-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.certificate-card {
  position: relative;
  overflow: hidden;
  padding: 1.2rem;
  border-radius: 1.3rem;
  background: linear-gradient(135deg, rgba(255,255,255,0.10), rgba(255,255,255,0.04));
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.certificate-card::before {
  content: '';
  position: absolute;
  inset: auto -30px -30px auto;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(125,211,252,0.25), transparent 70%);
  pointer-events: none;
}

.certificate-card:hover {
  transform: translateY(-6px);
  border-color: rgba(125,211,252,0.38);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.certificate-icon {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  margin-bottom: 0.8rem;
  background: linear-gradient(135deg, rgba(125,211,252,0.2), rgba(251, 113, 133, 0.18));
  color: #ffffff;
  font-size: 1.1rem;
}

.certificate-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.04rem;
  color: #ffffff;
}

.certificate-meta {
  display: inline-block;
  margin-bottom: 0.7rem;
  color: var(--accent);
  font-size: 0.86rem;
  font-weight: 600;
}

.certificate-card p {
  margin: 0 0 0.9rem;
  color: #dbe4ee;
  line-height: 1.7;
  font-size: 0.95rem;
}

.certificate-card .view-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 0.95rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.14);
  color: #f8fbff;
  font-size: 0.9rem;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.certificate-card .view-btn:hover {
  background: rgba(125,211,252,0.12);
  border-color: rgba(125,211,252,0.3);
}

.achievement-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.achievement-row span {
  padding: 0.7rem 0.95rem;
  border-radius: 999px;
  background: rgba(251, 113, 133, 0.12);
  color: #ffb3c2;
  border: 1px solid rgba(251, 113, 133, 0.24);
}

.contact-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 1rem; }
.contact-card { padding: 1.2rem; border-radius: 1.2rem; }
.contact-card h3 { margin-top: 0; }
.contact-card p { color: #dbe4ee; line-height: 1.7; }
.contact-form { display: grid; gap: 0.8rem; }
.contact-form input, .contact-form textarea {
  width: 100%; border: 1px solid rgba(255,255,255,0.14); background: rgba(255,255,255,0.06); color: white; border-radius: 0.9rem; padding: 0.9rem 1rem; font: inherit;
}
.contact-form textarea { min-height: 130px; resize: vertical; }
.contact-form button { border: 0; cursor: pointer; }
.contact-form .success { display: none; color: #7dd3fc; margin-top: 0.25rem; }
.contact-form.submitted .success { display: block; }
.contact-form.submitted button { opacity: 0.7; }

.scroll-top {
  position: fixed; right: 1.15rem; bottom: 1.15rem; width: 46px; height: 46px; border-radius: 50%; border: 0; background: linear-gradient(135deg, var(--accent), var(--accent-strong)); color: #03111f; display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); z-index: 35; opacity: 0; pointer-events: none; transform: translateY(12px); transition: opacity 0.2s ease, transform 0.2s ease;
}
.scroll-top.show { opacity: 1; pointer-events: auto; transform: translateY(0); }

.footer { padding: 0 0 2rem; text-align: center; color: #8ca1b4; font-size: 0.9rem; }

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

@keyframes drift { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(30px, 25px, 0); } }
@keyframes pulseRing { 0%, 100% { transform: scale(1); opacity: 0.75; } 50% { transform: scale(1.02); opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 0%,100% { transform: translateY(0px); } 50% { transform: translateY(-12px); } }

@media (max-width: 900px) {
  .hero, .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .projects-grid { grid-template-columns: 1fr 1fr; }
  .certificate-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .menu-toggle { display: inline-flex; }
  .site-nav {
    position: absolute; right: 1rem; top: 4.25rem; flex-direction: column; align-items: flex-start; width: min(220px, calc(100% - 2rem)); padding: 1rem; border-radius: 1rem; background: rgba(7, 11, 20, 0.95); border: 1px solid rgba(255,255,255,0.12); box-shadow: var(--shadow); transform: translateY(-10px); opacity: 0; pointer-events: none; transition: all 0.2s ease;
  }
  .site-nav.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav-actions .resume-pill { display: none; }
  .hero { padding-top: 3rem; }
  .skills-grid, .projects-grid, .certificate-grid, .stats-grid { grid-template-columns: 1fr; }
  .hero-visual { min-height: 340px; }
  .profile-shell img { height: 340px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .cursor { display: none; }
}
