:root {
  --bg: #0e1117;
  --panel: #161b22;
  --text: #ffffff;
  --muted: #8b949e;
  --accent: #3b82f6;
  --highlight: #f2b84b;
  --border: #30363d;
  --tag-bg: rgba(59, 130, 246, 0.1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* Smooth scroll animation for sections */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section[id] {
  will-change: opacity, transform;
}

/* Apply Inter to all text elements */
p, span, div, a, li, td, th, label, input, textarea, select, button {
  font-family: "Inter", sans-serif;
}

/* Header and Navigation */
.site-header {
  position: sticky;
  top: 0;
  background: rgba(15, 20, 25, 0.8);
  z-index: 100;
  border-bottom: 1px solid var(--border);
}

.nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  position: relative;
}

.nav-links-wrapper {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav ul {
  display: flex;
  gap: 2rem;
  list-style: none;
  align-items: center;
  margin: 0;
  padding: 0;
}

.nav li {
  position: relative;
  display: flex;
  align-items: center;
}

.nav a {
  font-family: "Inter", sans-serif;
  color: #9CA3AF;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s;
  display: block;
  padding: 0;
}

.nav a.active {
  color: var(--accent);
}

.nav li a.active::after {
  content: '';
  position: absolute;
  bottom: -1rem;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--accent);
}

.nav a:hover:not(.blog-pill):not(.active) {
  color: var(--muted);
}

.blog-pill {
  background: var(--highlight) !important;
  color: #000 !important;
  width: 79px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  font-weight: 500;
  text-decoration: none !important;
  padding: 0;
  text-align: center;
  line-height: 36px;
  vertical-align: middle;
  position: relative;
}

.blog-pill:hover {
  opacity: 0.9;
}

.blog-pill.active {
  background: transparent !important;
  color: var(--highlight) !important;
  width: auto !important;
  height: auto !important;
  line-height: normal !important;
  border-radius: 0 !important;
  padding: 0 !important;
  display: inline-block !important;
}

.blog-pill.active::after {
  content: '';
  position: absolute;
  bottom: -1rem;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--highlight);
}

/* Hero Section */
.hero {
  text-align: center;
  padding: 4rem 1rem 6rem;
  background: linear-gradient(to bottom, #0F1419, #1A1F29);
  width: 100%;
}

.hero > * {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.avatar {
  width: 350px;
  height: 350px;
  border-radius: 50%;
  margin-bottom: 1.5rem;
  object-fit: cover;
}

.hero h1 {
  font-family: "Tenor Sans", sans-serif;
  font-size: 60px;
  font-weight: 400;
  font-style: normal;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.subtitle {
  font-family: "Inter", sans-serif;
  font-size: 20px;
  color: #9CA3AF;
  margin-bottom: 0.25rem;
}

.institution {
  font-family: "Inter", sans-serif;
  font-size: 18px;
  color: #9CA3AF;
  margin-bottom: 2rem;
}

.socials {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.socials a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-icon {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
  flex-shrink: 0;
}

.scroll-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 2rem;
  opacity: 0.6;
}

.scroll-icon {
  width: 16px;
  height: 16px;
}

/* Sections */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

#projects.section {
  background: #1A1F29;
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
  padding: 5rem 2rem;
}

#projects.section h2,
#projects.section .section-subtitle {
  width: 1168px;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
  box-sizing: border-box;
}

#projects.section .card-grid {
  width: 1168px;
  max-width: 100%;
}

#projects.section .github-link-container {
  width: 1168px;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.section h2 {
  font-family: "Tenor Sans", sans-serif;
  font-size: 2rem;
  font-weight: 400;
  font-style: normal;
  margin-bottom: 1rem;
  color: var(--text);
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
  padding-right: 0;
}

/* About Section */
.about-content {
  max-width: 904px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

#about .section h2 {
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
  margin-top: 0;
  padding-left: 0;
  padding-right: 0;
  color: #E4E6EB;
  width: 100%;
  box-sizing: border-box;
  text-align: left;
}

.section-subtitle {
  color: var(--muted);
  font-size: 1rem;
  margin-bottom: 3rem;
}

.about-text {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  line-height: 1.8;
  color: #E4E6EB;
  opacity: 0.8;
  margin-bottom: 3rem;
  margin-top: 0;
  max-width: 100%;
  width: 100%;
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
  padding-right: 0;
  box-sizing: border-box;
  text-align: left;
}

.about-text p {
  margin-bottom: 1rem;
  color: #E4E6EB;
}

.about-text p:last-child {
  margin-bottom: 0;
  color: #E4E6EB;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 436px);
  gap: 2rem;
  margin-bottom: 1.5rem;
  justify-content: center;
  margin-left: auto;
  margin-right: auto;
}

.card {
  background: #1A1F29;
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid #2D3748;
  width: 436px;
  height: 369px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  flex-shrink: 0;
}

.card-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.card h3 {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  font-style: normal;
  color: var(--text);
  margin: 0;
}

.card-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  flex: 1;
}

.education-item,
.experience-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.degree,
.position {
  font-family: "Tenor Sans", sans-serif;
  font-weight: 400;
  font-style: normal;
  color: var(--text);
  font-size: 0.95rem;
  margin: 0;
  line-height: 1.3;
}

.institution-detail,
.company {
  font-family: "Inter", sans-serif;
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
  line-height: 1.3;
}

.date {
  font-family: "Inter", sans-serif;
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0;
  line-height: 1.3;
}

.research-interests-card {
  background: #1A1F29;
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid #2D3748;
  margin-top: 0;
  width: 904px;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.research-interests-title {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.25rem;
  font-weight: 400;
  font-style: normal;
  margin-bottom: 1rem;
  color: #E4E6EB;
  margin-top: 0;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.tag {
  background: #161b22;
  color: var(--accent);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
  border: 1px solid var(--accent);
  font-family: "Inter", sans-serif;
}

/* Projects Section */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 368px);
  gap: 2rem;
  margin-bottom: 3rem;
  justify-content: flex-start;
  width: 1168px;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}


.project-card {
  background: #0F1419;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid #2D3748;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.2s;
  position: relative;
  width: 368px;
  height: 294px;
  box-sizing: border-box;
  overflow: hidden;
}

.project-card:hover {
  border-color: var(--accent);
}

.project-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0;
  flex-shrink: 0;
}

.project-icon {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
  flex-shrink: 0;
}

.project-github-link {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
  transition: opacity 0.2s;
  cursor: pointer;
  z-index: 10;
  position: relative;
  text-decoration: none;
}

.project-github-link:hover {
  opacity: 1;
}

.github-icon {
  width: 20px;
  height: 20px;
}

.project-card h3 {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  font-style: normal;
  color: var(--text);
  margin: 0;
  flex-shrink: 0;
}

.project-description {
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.5;
  flex-grow: 1;
  font-family: "Inter", sans-serif;
  margin: 0;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  -webkit-box-orient: vertical;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
  flex-shrink: 0;
}

.project-tag {
  background: #1A1F29;
  color: #E4E6EB;
  padding: 0.35rem 0.75rem;
  border-radius: 4px;
  font-size: 0.8rem;
  border: 1px solid #2D3748;
  font-family: "Inter", sans-serif;
}

.github-link-container {
  text-align: center;
  margin-top: 2rem;
}

.inline-link {
  color: var(--accent);
  text-decoration: none;
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: opacity 0.2s;
  font-family: "Inter", sans-serif;
}

.inline-link:hover {
  opacity: 0.8;
}

.external-icon {
  font-size: 1rem;
}

/* Publications Section */
#publications.section h2,
#publications.section .section-subtitle,
#publications.section .publications-list,
#publications.section .scholar-link-container {
  max-width: 904px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

.publications-list {
  margin-bottom: 3rem;
}

.pub-year-group {
  margin-bottom: 3rem;
}

.pub-year {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.5rem;
  font-weight: 400;
  font-style: normal;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.pub-items {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding-left: 0;
}

.pub-item {
  padding-left: 1rem;
  padding-bottom: 1.5rem;
  border-left: 2px solid rgba(59, 130, 246, 0.3);
  position: relative;
  transition: border-color 0.2s;
}

.pub-item:last-child {
  padding-bottom: 0;
}

.pub-title {
  font-family: "Tenor Sans", sans-serif;
  font-weight: 400;
  color: #E4E6EB;
  font-size: 1rem;
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.pub-authors {
  font-family: "Inter", sans-serif;
  color: #9CA3AF;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
  line-height: 1.5;
}

.pub-journal {
  font-family: "Inter", sans-serif;
  color: #9CA3AF;
  font-size: 0.85rem;
  font-style: italic;
}

.scholar-link-container {
  text-align: center;
  margin-top: 2rem;
}

/* Contact Section */
#contact.section {
  background: #1A1F29;
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
  padding: 5rem 2rem;
  height: 478px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
}

#contact.section h2,
#contact.section .section-subtitle {
  width: 1168px;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
  box-sizing: border-box;
  text-align: left;
}

#contact.section .section-subtitle {
  margin-bottom: 0;
}

#contact.section .contact-grid {
  max-width: 904px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

.contact {
  padding-bottom: 4rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 277px);
  gap: 2rem;
  margin-top: 48px;
  justify-content: center;
}

.contact-card {
  background: #1A1F29;
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid #2D3748;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
  width: 277px;
  height: 144px;
  box-sizing: border-box;
}

.contact-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0;
}

.contact-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  filter: brightness(0) saturate(100%) invert(48%) sepia(79%) saturate(2476%) hue-rotate(200deg) brightness(98%) contrast(101%);
}

.contact-card h3 {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  font-style: normal;
  color: #E4E6EB;
  margin: 0;
}

.contact-card p {
  font-family: "Inter", sans-serif;
  color: #9CA3AF;
  font-size: 0.95rem;
  margin: 0;
  line-height: 1.5;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent);
  color: #0F1419;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  font-family: "Inter", sans-serif;
  transition: opacity 0.2s;
  margin-top: 0;
  border: none;
  cursor: pointer;
}

.download-btn:hover {
  opacity: 0.9;
}

.download-icon {
  width: 16px;
  height: 16px;
  filter: brightness(0);
}

/* Footer */
.footer {
  background: #0F1419;
  border-top: none;
  border-bottom: 1px solid #2D3748;
  padding: 0;
  margin-top: 0;
  height: 96px;
  display: flex;
  align-items: center;
}

.footer-content {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 0 2rem;
  box-sizing: border-box;
}

.footer-content p {
  font-family: "Inter", sans-serif;
  color: #9CA3AF;
  font-size: 0.9rem;
  margin: 0;
  text-align: left;
}

.footer-name-link {
  color: #9CA3AF;
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  transition: color 0.2s;
}

.footer-name-link:hover {
  color: var(--accent);
}

.footer-socials {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-left: auto;
}

.footer-icon {
  width: 20px;
  height: 20px;
  filter: brightness(0) saturate(100%) invert(48%) sepia(79%) saturate(2476%) hue-rotate(200deg) brightness(98%) contrast(101%);
  transition: opacity 0.2s;
  opacity: 1;
}

/* Blog Page Styles */
.blog-section {
  padding: 3rem 2rem;
  width: 100%;
  min-height: 100vh;
}

.blog-container {
  max-width: 904px;
  margin: 0 auto;
}

.back-link {
  font-family: "Inter", sans-serif;
  color: rgba(156, 163, 175, 0.7);
  text-decoration: none;
  font-size: 0.95rem;
  display: inline-block;
  margin-bottom: 2rem;
  transition: opacity 0.2s;
}

.back-link:hover {
  opacity: 1;
}

.blog-title {
  font-family: "Tenor Sans", sans-serif;
  font-size: 2rem;
  font-weight: 400;
  font-style: normal;
  color: #E4E6EB;
  margin-bottom: 3rem;
  margin-top: 0;
}

.blog-posts {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.blog-card {
  background: #1A1F29;
  border: 1px solid #2D3748;
  border-radius: 8px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.blog-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: "Inter", sans-serif;
  font-size: 0.875rem;
  color: #9CA3AF;
  margin-bottom: 1rem;
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.meta-icon {
  width: 16px;
  height: 16px;
  opacity: 0.7;
}

.meta-separator {
  color: #9CA3AF;
  opacity: 0.5;
}

.blog-card-title {
  font-family: "Tenor Sans", sans-serif;
  font-size: 1.5rem;
  font-weight: 400;
  font-style: normal;
  color: #E4E6EB;
  margin: 0;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.blog-snippet {
  font-family: "Inter", sans-serif;
  font-size: 0.95rem;
  color: #9CA3AF;
  line-height: 1.6;
  margin: 0;
  margin-bottom: 1rem;
}

.blog-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.blog-tag {
  background: transparent;
  color: #9CA3AF;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.875rem;
  font-family: "Inter", sans-serif;
  border: 1px solid #2D3748;
}

.read-article-link {
  font-family: "Inter", sans-serif;
  color: var(--accent);
  text-decoration: none;
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
  transition: opacity 0.2s;
}

.read-article-link:hover {
  opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav {
    padding: 1rem;
  }

  .nav ul {
    gap: 1rem;
    font-size: 0.9rem;
  }

  .hero {
    padding: 3rem 1rem 4rem;
  }

  .hero h1 {
    font-size: 40px;
  }

  .section {
    padding: 3rem 1.5rem;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }
  
  .info-grid .card {
    width: 100%;
    height: auto;
    min-height: 369px;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .card-grid {
    grid-template-columns: 1fr;
    justify-content: center;
  }
  
  .project-card {
    width: 100%;
    max-width: 368px;
    height: auto;
    min-height: 294px;
  }
  
  .project-card:nth-child(4),
  .project-card:nth-child(5) {
    grid-column: 1;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }
}
