* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: 'Fira Code', monospace;
  color: #eee;
  background-color: #0d0d0d;
  background-image: 
    linear-gradient(rgba(126, 217, 87, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 217, 87, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  overflow-x: hidden;
  animation: moveGrid 5s linear infinite;
  scroll-behavior: smooth;
}

@keyframes moveGrid {
  0% { background-position: 0 0, 0 0; }
  100% { background-position: 40px 40px, 40px 40px; }
}


/* Links */
a {
  color: #7ed957;
  text-decoration: none;
  transition: color 0.2s;
}
a:hover { color: #9fe87f; }

/* Header */
header {
  background: #111;
  color: #eee;
  padding: 24px 20px;
  border-bottom: 1px solid #222;
  position: sticky;
  top: 0;
  z-index: 1000;
}

header h1 {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 8px;
}

/* Navigation */
nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

nav a {
  position: relative;
  font-weight: 600;
  margin-right: 16px;
}

nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0%;
  height: 2px;
  background-color: #7ed957;
  transition: width 0.3s ease;
}
nav a:hover::after,
nav a.active::after {
  width: 100%;
}
nav a.active { color: #9fe87f; }

/* Layout */
main {
  max-width: 1100px;
  margin: 36px auto;
  padding: 0 20px;
}

/* Profile Section */
.profile {
  display: grid;
  grid-template-columns: 1fr 200px;
  align-items: center;
  gap: 20px;
  margin-bottom: 36px;
  background: #1b1b1b;
  border-radius: 12px;
  padding: 28px;
  border: 1px solid #333;
}

.statement h2 {
  font-size: 24px;
  margin-bottom: 10px;
  color: #fff;
}

.statement p {
  color: #ccc;
  line-height: 1.6;
  font-size: 16px;
}

.profile-image img {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid #444;
  transition: transform 0.3s, box-shadow 0.3s;
}
.profile-image img:hover { transform: scale(1.05); }

/* === Horizontal Tech Stack Section - Static & Compact === */
.skills-section {
  background: #1b1b1b;
  border-radius: 12px;
  border: 1px solid #333;
  padding: 15px 10px;
  margin-bottom: 48px;
  text-align: center;
}

.skills-section h2 {
  color: #7ed957;
  font-size: 20px;
  margin-bottom: 10px;
}

.tech-box.horizontal {
  background: #222; /* match project cards */
  border: 1px solid #333;
  border-radius: 10px;
  padding: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 100%;
  margin: 0 auto;
  overflow-x: auto;
}
/* Note: The image styling inside tech-track/tech-row is now outside of tech-track in the original file, so adapting based on the original styles and the new additions. */
.tech-row {
  display: flex;
  flex-wrap: nowrap; /* prevent wrapping */
  justify-content: center;
  align-items: center;
  gap: 15px; /* space between icons */
}

.tech-row img {
  width: 25px;  /* much smaller icons */
  height: 25px;
  filter: grayscale(100%);
  opacity: 0.85;
  transition: transform 0.3s ease, filter 0.3s ease, opacity 0.3s ease;
}

.tech-row img:hover {
  transform: scale(1.3);
  filter: grayscale(0%);
  opacity: 1;
  box-shadow: 0 0 8px #7ed957;
}

/* Scrollbar for horizontal overflow */
.tech-box.horizontal::-webkit-scrollbar {
  height: 5px;
}
.tech-box.horizontal::-webkit-scrollbar-thumb {
  background: #7ed957;
  border-radius: 3px;
}
.tech-box.horizontal::-webkit-scrollbar-track {
  background: #222;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: max-content;
  background-color: #222; /* tooltip background */
  color: #7ed957; /* green text */
  text-align: center;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 12px;
  position: absolute;
  bottom: 110%; /* above the icon */
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none; /* prevents blocking hover */
}

.tooltip .tooltiptext::after {
  content: "";
  position: absolute;
  top: 100%; /* bottom of tooltip */
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: #222 transparent transparent transparent;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}

/* Responsive tweaks */
@media (max-width: 900px) {
  .tech-row img { width: 20px; height: 20px; }
  .tech-row { gap: 10px; }
}
@media (max-width: 600px) {
  .tech-row img { width: 18px; height: 18px; }
  .tech-row { gap: 8px; }
}

/* Projects (Work Experience is also using this class) */
.projects {
  background: #1b1b1b;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #333;
  margin-bottom: 48px;
}

.projects-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.projects-header h2, 
.projects h2 {
  color: #7ed957;
  font-size: 20px;
  margin-bottom: 16px;
}

.view-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.view-links a {
  color: #7ed957;
  font-weight: 600;
  text-align: right;
  transition: color 0.2s;
}
.view-links a:hover { color: #9fe87f; }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
}

.project-card {
  background: #222;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid #333;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 10px #7ed95733;
}

.project-card h3 {
  color: #7ed957;
  font-size: 16px;
  margin-bottom: 8px;
}

.project-card a:hover { color: #9fe87f; }

.project-card p {
  color: #ccc;
  font-size: 14px;
  margin-bottom: 12px;
}

.meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}

.lang {
  background: #2b2b2b;
  color: #7ed957;
  padding: 4px 8px;
  border-radius: 999px;
}

.repo-link { color: #7ed957; }
.repo-link:hover { text-decoration: underline; }

/* === Achievements Section (New Card Design) === */
#achievements {
  background: #1b1b1b;
  border: 1px solid #333;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 48px;
  box-shadow: 0 0 8px rgba(126, 217, 87, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-align: center;
}

#achievements:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 15px rgba(126, 217, 87, 0.15);
}

#achievements h2 {
  color: #7ed957;
  font-size: 22px;
  margin-bottom: 20px;
  font-weight: 700;
  position: relative;
}

/* Decorative glow line under main title */
#achievements h2::after {
  content: '';
  display: block;
  height: 2px;
  width: 80px;
  background: linear-gradient(90deg, transparent, #7ed957, transparent);
  margin: 10px auto 20px auto;
  border-radius: 999px;
}

#achievements h4 {
  color: #9fe87f;
  font-size: 18px;
  margin: 20px 0 10px 0;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.achievements-list {
  list-style: none;
  padding: 0;
  margin-bottom: 20px;
}

.achievements-list li {
  color: #ccc;
  font-size: 15px;
  margin: 8px 0;
  padding: 8px 12px;
  background: #222;
  border-radius: 8px;
  border: 1px solid #2b2b2b;
  display: inline-block;
  transition: background 0.3s, transform 0.3s, box-shadow 0.3s;
}

.achievements-list li:hover {
  background: #272727;
  transform: translateY(-3px);
  box-shadow: 0 0 10px rgba(126, 217, 87, 0.15);
}

.achievements-list i {
  color: #7ed957;
  font-style: italic;
  opacity: 0.8;
}

/* === About Me Section === */
.about-me {
  background: #1b1b1b;
  border: 1px solid #333;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 48px;
  box-shadow: 0 0 8px rgba(126, 217, 87, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.about-me:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 15px rgba(126, 217, 87, 0.15);
}

.about-me h2 {
  color: #7ed957;
  font-size: 22px;
  margin-bottom: 16px;
  text-align: center;
  font-weight: 700;
}

.about-me p {
  color: #ccc;
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 16px;
  text-align: justify;
}

/* Optional subtle glow line on top for a modern accent */
.about-me::before {
  content: '';
  display: block;
  height: 2px;
  width: 80px;
  background: linear-gradient(90deg, transparent, #7ed957, transparent);
  margin: 0 auto 20px auto;
  border-radius: 999px;
}

.yap {
  background: #1b1b1b;
  border: 1px solid #333;
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 48px;
  box-shadow: 0 0 8px rgba(126, 217, 87, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.yap:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 15px rgba(126, 217, 87, 0.15);
}


.yap::before {
  content: '';
  display: block;
  height: 2px;
  width: 80px;
  background: linear-gradient(90deg, transparent, #7ed957, transparent);
  margin: 0 auto 20px auto;
  border-radius: 999px;
}


.yap h2 {
  color: #7ed957;
  font-size: 22px;
  margin-bottom: 16px;
  text-align: center;
  font-weight: 700;
}

.yap p {
  color: #ccc;
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 16px;
  text-align: justify;
}



/* === Footer === */
footer {
  background: linear-gradient(180deg, #0f0f0f 0%, #080808 100%);
  border-top: 1px solid #222;
  padding: 50px 20px 25px;
  margin-top: 80px;
  color: #ccc;
  position: relative;
  overflow: hidden;
}

/* Subtle glowing line animation */
footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 1px;
  background: linear-gradient(90deg, transparent, #7ed957, transparent);
  animation: scanline 6s linear infinite;
}

@keyframes scanline {
  0% { transform: translateX(-50%); }
  100% { transform: translateX(50%); }
}

/* Animated background “glow” dots */
footer::after {
  content: '';
  position: absolute;
  top: -100px;
  left: -100px;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 50% 0%, rgba(126, 217, 87, 0.08) 0%, transparent 70%);
  animation: pulseGlow 8s ease-in-out infinite alternate;
  z-index: 1;
  pointer-events: none; /* Make sure it doesn't interfere with clicks */
}

@keyframes pulseGlow {
  from { opacity: 0.4; transform: scale(1); }
  to { opacity: 0.8; transform: scale(1.2); }
}

/* Grid layout */
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.footer-section h2, .footer-section h3 {
  color: #7ed957;
  margin-bottom: 12px;
  font-weight: 700;
  text-shadow: 0 0 8px #7ed95755;
}

.footer-section p {
  color: #aaa;
  font-size: 14px;
  line-height: 1.6;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section ul li {
  margin-bottom: 8px;
}

.footer-section ul li a {
  color: #7ed957;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s, text-shadow 0.3s;
}

.footer-section ul li a:hover {
  color: #9fe87f;
  text-shadow: 0 0 8px #7ed957aa;
}

/* Bottom strip */
.footer-bottom {
  border-top: 1px solid #222;
  text-align: center;
  padding-top: 20px;
  margin-top: 30px;
  font-size: 13px;
  color: #888;
  position: relative;
  z-index: 2;
}

.footer-bottom .accent {
  color: #7ed957;
  font-weight: 600;
}


/* Responsive Profile */
@media (max-width: 900px) {
  .profile {
    grid-template-columns: 1fr 160px;
    padding: 20px;
  }
  .profile-image img {
    width: 160px;
    height: 160px;
  }
}

@media (max-width: 600px) {
  .profile {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .profile-image {
    justify-self: center;
  }
  .profile-image img {
    width: 140px;
    height: 140px;
  }
  
  /* Responsive footer */
  .footer-section h2, .footer-section h3 {
    text-align: center;
  }
  
  /* Responsive Achievements and About Me */
  #achievements {
    padding: 20px;
  }
  #achievements h2 {
    font-size: 20px;
  }
  #achievements h4 {
    font-size: 16px;
  }
  .achievements-list li {
    font-size: 14px;
    padding: 6px 10px;
  }

  .about-me {
    padding: 20px;
  }
  .about-me h2 {
    font-size: 20px;
  }
  .about-me p {
    font-size: 14px;
  }
}