/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: 'Segoe UI', sans-serif;
  line-height: 1.6;
  background: linear-gradient(to right, #1c1f2a, #2e2e4f); /* dark mode background */
  color: #e6eaec;
  scroll-behavior: smooth;
}

a {
  text-decoration: none;
  color: #e6eaec;
}
a:hover {
  text-decoration: underline;
}

/* Navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  background: #2c3e50;
  color: white;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.navbar a {
  color: white;
  margin-left: 15px;
  font-weight: 500;
  transition: color 0.3s;
}
.navbar a:hover {
  color: #f39c12;
}
.navbar .nav-right {
  display: flex;
  align-items: center;
}
.theme-toggle {
  margin-left: 30px;
  background: #2c3e50;
  color: #fff;
  border: none;
  border-radius: 20px;
  padding: 8px 18px;
  cursor: pointer;
  font-size: 16px;
  transition: background 0.3s, color 0.3s;
}
body.light-mode .theme-toggle {
  background: #f8f9fa;
  color: #2a3f5f;
  border: 1px solid #2a3f5f;
}

/* Hero Section */
.hero {
  text-align: center;
  padding: 60px 20px;
  background: linear-gradient(120deg, #2c3e50, #4b4376); /* dark mode gradient */
  color: white;
}

/* 🔹 Hero Image Slider (Image Switch Only) */
.hero-slider {
  position: relative;
  width: 220px;
  height: 220px;
  margin: 0 auto; /* center horizontally */
  border-radius: 50%;
  overflow: hidden;
  border: 6px solid #ffffff; /* ✅ single white border */
  box-sizing: border-box;
}

.hero-slider img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  opacity: 0;
  animation: fadeSlide 9s infinite;
}

/* each image fades in for 3s */
.hero-slider img:nth-child(1) { animation-delay: 0s; }
.hero-slider img:nth-child(2) { animation-delay: 3s; }
.hero-slider img:nth-child(3) { animation-delay: 6s; }

@keyframes fadeSlide {
  0%, 33% { opacity: 1; }
  33.01%, 100% { opacity: 0; }
}









.hero h1 {
  font-size: 36px;
}
.hero h1 span a {
  color: #b9e5a9;
}
.hero p {
  font-size: 18px;
}
.social-links {
  margin-top: 15px;
}
.social-links a {
  margin: 0 12px;
  font-size: 16px;
  color: white;
  border-bottom: 1px solid transparent;
  transition: all 0.3s;
}
.social-links a:hover {
  border-bottom: 1px solid white;
  color: #ffd700;
}

/* Sections */
.section {
  padding: 60px 20px;
  max-width: 1000px;
  margin: 50px auto;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  color: #2a3f5f;
}
h2 {
  font-size: 28px;
  margin-bottom: 20px;
  border-bottom: 2px solid #ddd;
  display: inline-block;
  color: #2a3f5f;
  text-align: center;
  display: block;
}

/* Skills Grid */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 15px;
  margin-top: 20px;
}
.skills-grid span {
  background: #ecf0f1;
  padding: 10px;
  border-radius: 8px;
  text-align: center;
  font-weight: bold;
  transition: background 0.3s, transform 0.3s;
}
.skills-grid span:hover {
  background: #3498db;
  color: white;
  transform: scale(1.05);
}

/* Projects */
.project-card {
  background: white;
  padding: 20px;
  margin: 20px 0;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.1);
}
.project-card h3 {
  color: #2c3e50;
  margin-bottom: 10px;
}
.project-card ul {
  margin-top: 10px;
  padding-left: 20px;
}
.project-card ul li {
  margin-bottom: 6px;
}
.project-card a {
  display: inline-block;
  margin-top: 12px;
  font-weight: bold;
  color: #2980b9;
  transition: color 0.3s;
}
.project-card a:hover {
  color: #1abc9c;
}

/* Achievements & Contact */
ul {
  padding-left: 20px;
}
ul li {
  margin-bottom: 10px;
  color: #34495e;
}
#contact a {
  color: #2c3e50;
  font-weight: 600;
}
#contact a:hover {
  color: #1abc9c;
}

/* Footer */
footer {
  background: #151520;
  color: #e6eaec;
  text-align: center;
  padding: 25px 10px;
  margin-top: 60px;
  font-size: 14px;
}
footer a {
  color: #ffd700;
  font-weight: bold;
  text-decoration: underline;
}
footer a:hover {
  color: #1abc9c;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeIn 1.2s ease forwards;
}
.fade-up {
  opacity: 0;
  transform: translateY(50px);
}
.fade-up.show {
  animation: fadeInUp 1s ease forwards;
}
@keyframes fadeIn {
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

/* Slide title in */
.animated-title {
  font-size: 30px;
  background: linear-gradient(to right, #0066ff, #00c3ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 30px;
  animation: slideIn 1.1s ease-out forwards;
  opacity: 0;
  transform: translateX(-40px);
}
@keyframes slideIn {
  to { opacity: 1; transform: translateX(0); }
}
.nav-left {
  display: flex;
  align-items: center;
  gap: 20px;
  overflow: hidden;
  position: relative;
}
.brand {
  font-weight: bold;
  font-size: 22px;
}
.email-slide {
  white-space: nowrap;
  animation: slide-left-right 8s linear infinite;
  font-size: 14px;
  color: #f1c40f;
  position: relative;
}
@keyframes slide-left-right {
  0% { transform: translateX(-10%); opacity: 0; }
  10% { opacity: 1; }
  50% { transform: translateX(0%); opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateX(100%); opacity: 1; }
}

/* --- Light Mode Overrides --- */
body.light-mode {
  background: linear-gradient(to right, #fff3e0, #e0f7fa);
  color: #222;
}
body.light-mode .navbar {
  background: #f8f9fa;
  color: #222;
}
body.light-mode .navbar a {
  color: #222;
}
body.light-mode .navbar a:hover {
  color: #007bff;
}
body.light-mode .hero {
  background: linear-gradient(120deg, #d9a7c7, #fffcdc);
  color: #222;
}
body.light-mode .hero-slider img {
  border: 5px solid #222; /* match dark mode */
}
body.light-mode .skills-grid span {
  background: #f0f4f8;
  color: #222;
}
body.light-mode .skills-grid span:hover {
  background: #007bff;
  color: #fff;
}
body.light-mode .section {
  background: #f8f9fa;
  color: #222;
}
body.light-mode .project-card {
  background: #fff;
  color: #222;
}
body.light-mode .project-card h3 {
  color: #007bff;
}
body.light-mode .project-card a {
  color: #007bff;
}
body.light-mode .project-card a:hover {
  color: #17a2b8;
}
body.light-mode ul li {
  color: #222;
}
body.light-mode #contact a {
  color: #007bff;
}
body.light-mode #contact a:hover {
  color: #17a2b8;
}
body.light-mode footer {
  background: #f4f4f4;
  color: #222;
}
body.light-mode footer a {
  color: #007bff;
}
body.light-mode footer a:hover {
  color: #17a2b8;
}
