/* Reset & Global */
body, html {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', sans-serif;
  background-color: var(--bg);
  color: var(--text);
  scroll-behavior: smooth;
  transition: background 0.3s, color 0.3s;
}

:root {
  --bg: #f9f9f9;
  --hero-bg: #ffffff;           /* <--- New Variable for Hero BG */
  --text: #212529;
  --primary: #0d6efd;
  --accent: #0b5ed7;
  --light: #ffffff;
  --muted: #6c757d;
  --border: #dee2e6;
  --shadow: rgba(0,0,0,0.05);
}

body.dark {
  --bg: #121212;
  --hero-bg: #1a1a1a;         /* <--- Switches hero section in dark mode */
  --text: #f1f3f5;
  --primary: #0dcaf0;
  --accent: #00b5d4;
  --light: #1e1e1e;
  --muted: #adb5bd;
  --border: #333;
  --shadow: rgba(255,255,255,0.05);
}

body.dark #lottie-animation svg {
  filter: brightness(0.8) contrast(1.2);
}

.container {
  max-width: 1100px;
  margin: auto;
  padding: 2rem 1rem;       /* Reduced vertical padding */
  display: flex;
  flex-direction: column;
  gap: 1 rem;              /* Slightly reduced internal spacing */
  align-items: flex-start;
  text-align: left;
}


.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-color: var(--hero-bg);
  padding: 4rem 1rem;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 720px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}


.hero-content h1 {
  font-size: 2.6rem;
  margin-top: 1.2rem;
  color: var(--primary);
}

.hero-tagline {
  font-size: 1.1rem;
  max-width: 680px;
  color: var(--text);
  margin-top: 1rem;
  line-height: 1.8;
}

.hero-wrapper {
  display: flex;
  align-items: flex-start;     /* PUSH CONTENT UP */
  justify-content: space-between;
  max-width: 1200px;
  margin: -20px auto 0 auto;   /* reduce white gap */
  padding: 3rem 2rem;          /* FIXED — smaller padding */
  gap: 40px;
  min-height: 70vh;            /* keeps hero visually tall but not empty */
}

.hero-left {
    flex: 1;
    max-width: 520px;           /* keeps it visually centered */
    text-align: left;         /* center text under profile pic */
}

.hero-right {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

#lottie-animation {
    width: 700px;               /* enlarge the animation */
    height: 700px;
}

/* Floating animation */
@keyframes floatAnim {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-18px); }
  100% { transform: translateY(0px); }
}

/* Mobile */
@media (max-width: 900px) {
  .hero-wrapper {
    flex-direction: column;
    gap: 2rem;
    text-align: center;
  }

  .hero-left {
    align-items: center;
  }

  #lottie-animation {
        width: 300px;
        height: 300px;
  }
}

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

.fade-in {
  opacity: 0;
  animation: fadeUp 1.2s ease forwards;
}

.fade-in:nth-child(1) { animation-delay: 0.2s; }
.fade-in:nth-child(2) { animation-delay: 0.4s; }
.fade-in:nth-child(3) { animation-delay: 0.6s; }
.fade-in:nth-child(4) { animation-delay: 0.8s; }


/* Section Divider */
.section-divider {
  width: 100%;
  max-width: 900px;
  height: 1px;
  background-color: var(--border);
  margin: 3rem auto;
}

#home {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  text-align: left;
  padding: 4rem 1rem 1rem;
}

h1, h2 {
  color: var(--primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-align: left;
  width: 100%;
  max-width: 900px;
  margin: 0 auto 1.5rem auto;
}

p {
  line-height: 1.6;
}

/* Navbar */
.navbar {
  background-color: var(--light);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo {
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo img {
  width: 24px;
  height: 24px;
  vertical-align: middle;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.2rem;
  margin: 0;
  padding: 0;
}

.nav-links li a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

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

/* Profile Image */
.profile-pic {
    width: 160px;                 /* previously 140px */
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 0 12px var(--shadow);
    margin-bottom: 1.2rem;
}

.subtitle {
  font-size: 1.1rem;
  color: var(--muted);
  margin-top: -0.5rem;
}

/* About Section */
#about {
  margin-top: 0;
  padding-top: 1rem;  /* If needed */
}


/* Skills */
.skills-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: flex-start;
  text-align: left;
}

.skill-name {
  font-weight: 500;
  margin-bottom: 0.3rem;
}

.skill-bar {
  background-color: var(--border);
  border-radius: 5px;
  overflow: hidden;
}

.skill-fill {
  height: 20px;
  background-color: var(--primary);
  color: white;
  padding-left: 8px;
  line-height: 20px;
  font-size: 0.9rem;
  transition: width 1s ease-in-out;
}

/* Projects */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  width: 100%;
}

.project-card {
  background-color: var(--light);
  border: none;
  padding: 2rem;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s, box-shadow 0.3s;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 24px var(--shadow);
}

.project-card h3 {
  margin-top: 0;
  color: var(--primary);
  font-size: 1.2rem;
}

.project-card p {
  color: var(--text);
  font-size: 0.95rem;
}

.project-card a {
  display: inline-block;
  margin-top: 0.8rem;
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}

/* Blogs */
/* Carousel wrapper */
.blog-carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    overflow: hidden;
}

/* Horizontal carousel */
.blog-carousel {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 20px 0;
    scroll-behavior: smooth;
}

.blog-carousel::-webkit-scrollbar {
    display: none; /* hide scrollbar */
}

/* Blog card */
.blog-card {
    min-width: 320px;
    background: var(--light);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transition: all 0.2s ease;
}

body.dark .blog-card {
    background: #2c2c2c; /* grey instead of black */
}

/* Card hover */
.blog-card:hover {
    transform: translateY(-5px);
}

/* Thumbnail */
.blog-thumbnail {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
}

.blog-read-btn {
    display: inline-block;
    margin-top: 0.8rem;
    color: var(--primary);        /* Your blue */
    text-decoration: none;
    font-weight: 600;             /* Match project cards */
    transition: color 0.2s ease;
}

.blog-read-btn:hover {
    color: var(--accent);         /* darker blue hover */
    text-decoration: underline;
}

/* Buttons */
.carousel-btn {
    background-color: var(--primary);        /* Your blue */
    border: none;
    padding: 12px 18px;
    border-radius: 50%;
    color: white;                             /* White arrow */
    font-size: 26px;
    cursor: pointer;
    transition: 0.25s ease;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.carousel-btn:hover {
    background-color: var(--accent);          /* Slightly darker blue */
    transform: scale(1.08);
}

/* Dark mode */
body.dark .carousel-btn {
    background-color: var(--primary);         /* Still blue */
    color: white;
}

/* TimeLine --> EXPERIENCE */

.timeline {
  position: relative;
  border-left: 3px solid var(--primary);
  padding-left: 1rem;
  margin-top: 2rem;
}

.timeline-item {
  position: relative;
  margin-bottom: 2.5rem;
}

.timeline-dot {
  position: absolute;
  top: 0;
  left: -10px;
  width: 16px;
  height: 16px;
  background-color: var(--primary);
  border-radius: 50%;
  box-shadow: 0 0 6px var(--primary);
}

.timeline-content {
  margin-left: 0;
  padding-left: 1rem;
}

.timeline-content h2 {
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
  color: var(--primary);
  text-align: left;
}

.timeline-date {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
  display: block;
  text-align: left;
}

.timeline-content p {
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
  text-align: left;
}

#experience .timeline-content h2 {
  text-align: left;
  width: 100%;
  margin-left: 0;
}

.minimal-exp {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-left: 1rem;
}

.exp-logo-minimal {
  width: 70px;
  height: 70px;
  object-fit: contain;
  border-radius: 8px;
  background-color: white;
  padding: 0.3rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.minimal-exp .exp-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.minimal-exp .exp-text h2 {
  font-size: 1.05rem;
  margin: 0;
  color: var(--primary);
}

.minimal-exp .exp-text .timeline-date {
  font-size: 0.9rem;
  color: var(--muted);
}


/* Volunteering & Certifications */
.vol-cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  width: 100%;
}

.vol-cert-card {
  background-color: var(--light);
  border: none;
  padding: 2rem;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.vol-cert-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 24px var(--shadow);
}

.vol-cert-card h3 {
  margin-top: 0;
  color: var(--primary);
  font-size: 1.2rem;
}

.vol-cert-card p {
  color: var(--text);
  font-size: 0.95rem;
}

.vol-cert-card a {
  display: inline-block;
  margin-top: 1rem;
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.vol-cert-card a:hover {
  color: var(--accent);
}

.issuer-logo {
  width: 100%;
  max-width: 160px;         /* Limits it on large screens */
  height: 80px;             /* Gives height without distortion */
  object-fit: contain;
  display: block;
  margin-bottom: 1rem;
  padding: 0.5rem;
  background-color: white;  /* Optional, good for contrast */
  border-radius: 8px;
}

/* Resume */
.download-btn {
  background-color: var(--primary);
  color: #fff; 
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-block;
  margin-top: 1rem;
  transition: background-color 0.3s ease;
}

.download-btn:hover {
  background-color: var(--accent);
}

/* Contact Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 600px;
  margin: 2rem auto 0 auto;
}

.contact-form input,
.contact-form textarea {
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 5px;
  font-size: 1rem;
  background-color: var(--light);
  color: var(--text);
}

.contact-form button {
  background-color: var(--primary);
  color: #fff;
  padding: 0.75rem;
  font-weight: bold;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

.contact-form button:hover {
  background-color: var(--accent);
}

.footer {
  text-align: center;
  padding: 1.5rem;
  background-color: var(--light);
  color: var(--muted);
  margin-top: 3rem;
  border-top: 1px solid var(--border);
}

.footer-links a {
  margin: 0 1rem;
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .hero-wrapper {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }

    .hero-left {
        text-align: center;
        max-width: 90%;
    }

    #lottie-animation {
        width: 330px;
        height: 330px;
    }

    .profile-pic {
        width: 130px;
        height: 130px;
    }
}


/* Dark Mode Toggle Button */
.theme-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 18px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  z-index: 999;
}

/* Reveal on Scroll */
[data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
[data-animate].visible {
  opacity: 1;
  transform: none;
}
