:root {
  --bg: #0c0f14;
  --bg-alt: #111620;
  --panel: rgba(255, 255, 255, 0.05);
  --text: #f3f5f7;
  --muted: #b7c0cc;
  --accent: #22d3ee;
  --accent-2: #60a5fa;
  --accent-3: #34d399;
  --border: rgba(255, 255, 255, 0.12);
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  --duration: 0.4s;
  --timing: cubic-bezier(0.23, 1, 0.32, 1);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  background:
    radial-gradient(
      1200px 600px at 10% 0%,
      rgba(34, 211, 238, 0.18),
      transparent 60%
    ),
    radial-gradient(
      800px 600px at 90% 10%,
      rgba(96, 165, 250, 0.18),
      transparent 60%
    ),
    var(--bg);
  color: var(--text);
  font-family: "Space Grotesk", system-ui, sans-serif;
  line-height: 1.6;
}

body {
  min-height: 100vh;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Parallax and Scroll Effects */
.parallax-layer {
  position: relative;
  will-change: transform;
}

.parallax-layer.hero-accent {
  position: absolute;
  opacity: 0.4;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(20px);
  }
}

/* Section Scroll Transitions */
.section {
  padding: 70px 8vw;
  position: relative;
  overflow: hidden;
  transition: background-color 0.6s ease;
}

.section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(34, 211, 238, 0.3) 50%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.section.in-view::before {
  opacity: 1;
}

/* Scroll-based color transitions */
.section:nth-child(2) {
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(34, 211, 238, 0.03) 100%
  );
}

.section:nth-child(3) {
  background: linear-gradient(
    180deg,
    rgba(60, 165, 250, 0.02) 0%,
    transparent 100%
  );
}

.section:nth-child(4) {
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(52, 211, 153, 0.02) 100%
  );
}

/* Scroll reveal animations */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Section title animations */
.section-title {
  position: relative;
}

.section-title h2 {
  letter-spacing: 0.5px;
  transition: all 0.6s ease;
}

.section.in-view .section-title h2 {
  letter-spacing: 1px;
}

/* Image reveal on scroll */
.image-reveal {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
}

.image-reveal img {
  will-change: transform;
  transition: transform 0.6s ease;
}

.image-reveal:hover img {
  transform: scale(1.05);
}

/* Text stagger effect */
.text-stagger {
  opacity: 0;
  animation: staggerText 0.6s ease-out forwards;
}

@keyframes staggerText {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.noise {
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
  mix-blend-mode: soft-light;
  pointer-events: none;
  z-index: 0;
}

/* Navigation */
.nav-links a {
  position: relative;
  color: var(--muted);
  transition: color 0.3s ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-links a:hover::after {
  width: 100%;
}

/* Hero Section */
.hero {
  padding: 70px 8vw 60px;
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 8vw;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(12, 15, 20, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  margin: 0 -8vw 40px -8vw;
}

.brand {
  font-family: "Fraunces", serif;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: color 0.3s ease;
  margin-left: 12px;
}

.brand:hover {
  color: var(--accent);
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(34, 211, 238, 0.2);
  transition: all 0.3s ease;
}

.brand:hover .avatar {
  border-color: var(--accent);
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.25);
}

.nav-links {
  display: flex;
  gap: 24px;
  font-size: 13px;
  color: var(--muted);
  margin-right: 12px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 50px;
  align-items: center;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 3px;
  font-size: 11px;
  color: var(--accent);
  font-weight: 600;
}

h1 {
  font-family: "Fraunces", serif;
  font-size: clamp(40px, 5vw, 64px);
  margin: 12px 0 16px;
  line-height: 1.2;
  background: linear-gradient(
    120deg,
    var(--text) 0%,
    var(--accent) 50%,
    var(--accent-2) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientShift 6s ease infinite;
}

@keyframes gradientShift {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.lead {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.7;
  max-width: 520px;
}

.hero-cta {
  display: flex;
  gap: 14px;
  margin-top: 28px;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  padding: 12px 18px;
  border-radius: 999px;
  font-size: 14px;
  letter-spacing: 0.2px;
  background: transparent;
  color: var(--text);
  transition: all 0.3s var(--timing);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.08);
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.btn:hover::before {
  transform: translateX(0);
}

.btn:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 12px 24px rgba(34, 211, 238, 0.1);
}

.btn:active {
  transform: translateY(0);
}

.btn.primary {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  color: #04131a;
  border: none;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.25);
}

.btn.primary:hover {
  box-shadow: 0 12px 32px rgba(34, 211, 238, 0.4);
}

.btn.ghost {
  background: rgba(255, 255, 255, 0.06);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn.small {
  padding: 10px 14px;
  font-size: 13px;
}

.hero-card {
  position: relative;
  padding: 26px;
  border-radius: 20px;
  background: linear-gradient(
    160deg,
    rgba(255, 255, 255, 0.06),
    rgba(255, 255, 255, 0.02)
  );
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: all 0.3s var(--timing);
  backdrop-filter: blur(10px);
}

.hero-card:hover {
  border-color: rgba(34, 211, 238, 0.3);
  background: linear-gradient(
    160deg,
    rgba(255, 255, 255, 0.08),
    rgba(255, 255, 255, 0.04)
  );
  box-shadow: 0 30px 100px rgba(34, 211, 238, 0.15);
}

.portrait {
  width: 100%;
  border-radius: 16px;
  object-fit: cover;
  aspect-ratio: 4 / 5;
  margin-bottom: 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.about-photo {
  display: flex;
  align-items: center;
  justify-content: center;
}

.about-photo .portrait {
  margin-bottom: 0;
  max-width: 260px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}
.stat-label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 2px;
}
.stat-value {
  font-size: 18px;
  font-weight: 600;
}

.accent {
  position: absolute;
  width: 200px;
  height: 200px;
  right: -40px;
  bottom: -40px;
  background: radial-gradient(
    circle at center,
    rgba(52, 211, 153, 0.8),
    transparent 70%
  );
  opacity: 0.4;
}

main {
  position: relative;
  z-index: 1;
}

.section {
  padding: 70px 8vw;
}

.section.alt {
  background: var(--bg-alt);
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 30px;
}

.section-title h2 {
  font-family: "Fraunces", serif;
  font-size: 30px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-title h2::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 24px;
  background: linear-gradient(180deg, var(--accent), var(--accent-3));
  border-radius: 2px;
}

.section-title p {
  color: var(--muted);
  max-width: 520px;
  margin: 0;
}

.about-grid,
.skills-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.about-card,
.skill,
.project-card,
.resume-card,
.contact-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px;
  backdrop-filter: blur(10px);
  transition: all 0.3s var(--timing);
}

.about-card:hover,
.skill:hover,
.resume-card:hover {
  border-color: rgba(34, 211, 238, 0.3);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.about-card h3 {
  margin-top: 0;
  font-size: 18px;
}

.skill {
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  padding-bottom: 8px;
}
\n .skill-title {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 12px;
  color: var(--accent);
  font-weight: 600;
}

.skill-proficiency {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 8px;
}

.skill-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 3px;
  animation: fillBar 1.2s ease-out 0.3s forwards;
  width: 0%;
}

@keyframes fillBar {
  to {
    width: 100%;
  }
}

.skill-logos {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.skill-logos img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: all 0.3s var(--timing);
}

.skill-logos img:hover {
  background: rgba(34, 211, 238, 0.2);
  border-color: rgba(34, 211, 238, 0.5);
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 8px 20px rgba(34, 211, 238, 0.2);
}

.project-card {
  margin: 50px;
  display: grid;
  grid-template-columns: minmax(220px, 34%) 1fr;
  gap: 26px;
  align-items: stretch;
  padding: 22px;
  border-radius: 22px;
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.06),
    rgba(255, 255, 255, 0.015)
  );
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.35);
  transition: all 0.3s var(--timing);
}

.project-card.no-shot,
.project-card:not(:has(.project-shot)) {
  display: block;
}

.project-card:hover {
  border-color: rgba(34, 211, 238, 0.4);
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.09),
    rgba(255, 255, 255, 0.025)
  );
  box-shadow: 0 40px 80px rgba(34, 211, 238, 0.2);
  transform: translateY(-6px);
}

.project-shot {
  width: 100%;
  height: 100%;
  min-height: 220px;
  object-fit: cover;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  transition: all 0.3s var(--timing);
}

.project-shot.contain,
.project-shot.mobile-shot {
  width: auto;
  max-width: 100%;
  max-height: 290px;
  height: auto;
  object-fit: contain;
  justify-self: center;
  align-self: center;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4);
}

.project-card:hover .project-shot {
  box-shadow: 0 24px 60px rgba(34, 211, 238, 0.2);
}

.project-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}

.project-body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
\n .project-links {
  margin-top: 6px;
}

.project-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
}

.chips {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.chips span {
  border: 1px solid;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
}

.chips span::before {
  content: "●";
  margin-right: 6px;
  font-size: 8px;
}

.chips span:nth-child(1) {
  color: #22d3ee;
  border-color: rgba(34, 211, 238, 0.3);
  background: rgba(34, 211, 238, 0.08);
}

.chips span:nth-child(2) {
  color: #60a5fa;
  border-color: rgba(96, 165, 250, 0.3);
  background: rgba(96, 165, 250, 0.08);
}

.chips span:nth-child(3) {
  color: #34d399;
  border-color: rgba(52, 211, 153, 0.3);
  background: rgba(52, 211, 153, 0.08);
}

.chips span:nth-child(n + 4) {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.3);
  background: rgba(245, 158, 11, 0.08);
}

.chips span:hover {
  transform: translateY(-2px);
  border-color: currentColor;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.tech-logos {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.tech-logos img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  transition: all 0.3s var(--timing);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.tech-logos img:hover {
  background: rgba(34, 211, 238, 0.2);
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 8px 20px rgba(34, 211, 238, 0.2);
}

.resume-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 12px;
  transition: all 0.3s var(--timing);
}

.contact-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.4);
  background: rgba(34, 211, 238, 0.1);
  box-shadow: 0 12px 32px rgba(34, 211, 238, 0.15);
}

.contact-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: all 0.3s var(--timing);
}

.contact-card:hover .contact-icon {
  background: rgba(34, 211, 238, 0.2);
  border-color: rgba(34, 211, 238, 0.5);
  transform: scale(1.1);
}

.contact-icon img {
  width: 26px;
  height: 26px;
}

.contact-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.snake-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  display: flex;
  justify-content: center;
  overflow: hidden;
}

.snake-card img {
  width: 100%;
  max-width: 900px;
}

.leetcode-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  display: flex;
  justify-content: center;
  overflow: hidden;
}

.leetcode-card img {
  width: 100%;
  max-width: 760px;
}

.leetcode-list {
  display: grid;
  gap: 10px;
}

.leetcode-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 14px;
  transition: all 0.3s var(--timing);
}

.leetcode-item:hover {
  border-color: rgba(34, 211, 238, 0.3);
  background: rgba(34, 211, 238, 0.08);
  transform: translateX(4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.tags {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  display: inline-block;
}

.tag:hover {
  transform: scale(1.05);
}

.tag.ok {
  color: #34d399;
  border-color: rgba(52, 211, 153, 0.3);
}
.tag.warn {
  color: #fbbf24;
  border-color: rgba(251, 191, 36, 0.3);
}
.tag.easy {
  color: #22d3ee;
  border-color: rgba(34, 211, 238, 0.3);
}
.tag.medium {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.3);
}
.tag.hard {
  color: #f87171;
  border-color: rgba(248, 113, 113, 0.3);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.stat-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  transition: all 0.3s var(--timing);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  backdrop-filter: blur(10px);
}

.stat-card:hover {
  border-color: rgba(34, 211, 238, 0.3);
  background: rgba(34, 211, 238, 0.08);
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: #22d3ee;
  line-height: 1;
}

.stat-label {
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer {
  text-align: center;
  padding: 30px 8vw 40px;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  .nav {
    margin: -50px -6vw 30px -6vw;
    padding: 12px 6vw;
    gap: 16px;
    flex-wrap: wrap;
  }
  .nav-links {
    gap: 16px;
    flex-wrap: wrap;
  }
  .section-title {
    flex-direction: column;
    align-items: flex-start;
  }
  .project-card,
  .resume-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .project-card {
    grid-template-columns: 1fr;
  }
  .project-shot {
    width: 100%;
    height: auto;
  }
  .project-shot.contain,
  .project-shot.mobile-shot {
    max-height: 360px;
    width: auto;
    margin: 0 auto;
  }
}

@media (max-width: 600px) {
  .hero {
    padding: 50px 6vw 50px;
  }
  .nav {
    padding: 10px 6vw;
    margin: -50px -6vw 30px -6vw;
  }
  .section {
    padding: 50px 6vw;
  }
  .hero-cta {
    flex-direction: column;
    align-items: stretch;
  }
  .btn {
    width: 100%;
  }
  h1 {
    font-size: clamp(32px, 5vw, 48px);
  }
  .nav-links {
    font-size: 12px;
    gap: 12px;
  }
}


/* User DEFINED */
::selection {
  background-color: #ffcc00; /* Yellow background */
  color: #000000;            /* Black text */
}

/* Required for Firefox support */
::-moz-selection {
  background-color: #ffcc00;
  color: #000000;
}