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

/* ===== Fonts & Base ===== */
body {
  font-family: "Poppins", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: #afafaf; /* base gray */
  color: #0d0106; /* dark black */
  font-size: 16px;
  line-height: 1.75;
}

/* ===== Container ===== */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

/* ===== Header ===== */
header {
  text-align: center;
  padding-bottom: 35px;
  background: #735290; /* purple */
  color: #afafaf;
  padding-top: 2rem;
}

header h1 {
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: #bf0d1c; /* red */
  margin-bottom: 0.5rem;
}

header .tagline {
  font-size: 1.3rem;
  color: #d1cfe0; /* lighter shade of purple */
  font-weight: 500;
  font-style: italic;
}

/* ===== Main Sections ===== */
main.container {
  margin-top: -80px;
}

section {
  background: #f2f2f2; /* light gray shade */
  border-radius: 20px;
  padding: 2rem;
  margin-bottom: 3rem;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

section:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* ===== Section Titles ===== */
h2 {
  color: #735290; /* purple */
  font-size: 1.8rem;
  margin-bottom: 1.2rem;
  position: relative;
}

h2::after {
  content: "";
  width: 60px;
  height: 4px;
  background: #bf0d1c; /* red */
  display: block;
  margin-top: 8px;
  border-radius: 4px;
}

/* Paragraphs & Lists */
p,
ul {
  color: #0d0106;
  margin-top: 0.8rem;
}

ul {
  padding-left: 1.5rem;
}

li {
  margin-bottom: 0.7rem;
}

strong {
  color: #bf0d1c; /* red */
}

/* ===== Project Links ===== */
.project-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.project-links a {
  color: #735290; /* purple */
  font-weight: 600;
  font-size: 1.1rem;
  text-decoration: none;
  border-left: 4px solid transparent;
  padding-left: 10px;
  transition: all 0.3s ease;
}

.project-links a:hover {
  border-left: 4px solid #bf0d1c; /* red */
  color: #bf0d1c;
}

/* ===== Contact Links ===== */
.links {
  list-style: none;
  padding: 0;
  margin-top: 1.2rem;
}

.links li {
  margin-bottom: 0.8rem;
}

.links a {
  color: #9c85ad; /* lighter shade of purple */
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
}

.links a:hover {
  color: #bf0d1c;
  text-decoration: underline;
}

/* ===== Footer ===== */
footer {
  text-align: center;
  font-size: 0.9rem;
  color: #afafaf;
  background: #735290; /* purple */
  padding: 2rem 0;
  font-style: italic;
}

/* ===== Bottom Cards ===== */
.bottom-cards {
  display: flex;
  gap: 2rem;
  margin-top: 3rem;
}

.bottom-cards > section {
  flex: 1;
  background: #f2f2f2;
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bottom-cards > section:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* ===== Gallery & Images ===== */
.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 1rem;
  justify-content: left;
}

.gallery img {
  max-width: 300px;
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.gallery img:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* ===== Section Subheadings ===== */
h3 {
  color: #9c85ad; /* lighter purple */
  font-size: 1.5rem;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
  border-bottom: 2px solid #bf0d1c; /* red */
  padding-bottom: 0.3rem;
}

/* ===== HERO HEADER ===== */
.hero {
  background: linear-gradient(135deg, #bf0d1c, #0d0106 100%);
  color: #afafaf;
  padding: 2rem 0.5rem 1rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 800;
  color: #ffffff; /* red */
}
.hero p {
  font-size: 1.3rem;
  color: #000000; /* lighter purple */
  margin: 1rem 0 2rem;
}
.btn {
  display: inline-block;
  padding: 1rem 2rem;
  background: #bf0d1c;
  color: #afafaf;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s ease;
}
.btn:hover {
  background: #900a18;
  transform: scale(1.05);
}

/* ===== SECTIONS ===== */
section {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  padding: 2rem;
  margin: 3rem 0;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-left: 6px solid #bf0d1c; /* red */
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}
section.visible {
  opacity: 1;
  transform: translateY(0);
}

h2 {
  color: #735290; /* purple */
  margin-bottom: 1rem;
}
h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 4px;
  background: #bf0d1c; /* red */
  margin-top: 6px;
  border-radius: 4px;
}

/* ===== PROJECT CARDS ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.project-card {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem;
  padding: 1.5rem;
  border-radius: 15px;
  background: linear-gradient(135deg, #bf0d1c, #735290);
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
}
.project-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  color: #000000;
}

/* ===== CONTACT CARDS ===== */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}
.contact-card {
  background: #735290; /* purple */
  color: #ffffff;
  padding: 1rem;
  border-radius: 12px;
  text-align: center;
  font-weight: 600;
  transition: all 0.3s ease;
}
.contact-card:hover {
  background: #bf0d1c;
  color: #0d0106;
  transform: translateY(-3px) scale(1.03);
}

/* ===== FOOTER ===== */
footer {
  background: linear-gradient(135deg, #735290, #0d0106);
  color: #afafaf;
  text-align: center;
  padding: 2rem;
  font-style: italic;
}

/* ===== ANIMATIONS ===== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}
.fade-in.delay-1 {
  transition-delay: 0.3s;
}
.fade-in.delay-2 {
  transition-delay: 0.6s;
}
.fade-up {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}
.fade-up.delay-1 {
  transition-delay: 0.3s;
}
.fade-up.delay-2 {
  transition-delay: 0.6s;
}
.fade-up.delay-3 {
  transition-delay: 0.9s;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 700px) {
  .hero h1 {
    font-size: 2.2rem;
  }
  .hero p {
    font-size: 1.1rem;
  }
}

/* ===== Back Button Styling ===== */
.back-button a {
  display: inline-block;
  margin: 1rem 0;
  padding: 10px 20px;
  background: #bf0d1c;
  color: #afafaf;
  font-weight: 600;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

.back-button a:hover {
  background: #900a18;
  transform: scale(1.05);
}

/* ===== Video Wrapper Styling ===== */
.video-wrapper {
  margin-top: 1rem;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.video-wrapper video {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* ===== GitHub Link Styling ===== */
.github-link a {
  display: inline-block;
  padding: 12px 25px;
  background: #735290;
  color: #afafaf;
  font-weight: bold;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.github-link a:hover {
  background: #bf0d1c;
  color: #fff;
  transform: scale(1.05);
}

/* ===== Lightbox Styling ===== */
.lightbox {
  display: none;
  position: fixed;
  z-index: 999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: center;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 12px;
}

/* ===== Gallery Image Hover ===== */
.gallery img:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}

/* ===== Section Subtle Animation ===== */
section {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}

section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Body & Container Upgrade ===== */
body {
  background: linear-gradient(120deg, #f7f8fa, #e2e6eb);
  color: #1a1a1a;
}

.container {
  padding: 4rem 2rem;
}

/* ===== Header Styling ===== */
header {
  background: linear-gradient(135deg, #bf0d1c, #735290);
  color: #fff;
  padding: 3rem 1rem 2rem;
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

header h1 {
  font-size: 3.2rem;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.25);
  color: white;
}

header .subheading {
  font-size: 1.5rem;
  font-style: italic;
  color: #f2f2f2;
  margin-top: 0.5rem;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.2);
}

/* ===== Section Styling ===== */
section {
  background: #ffffff;
  padding: 2.5rem;
  border-radius: 25px;
  margin-bottom: 3.5rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
}

section:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* ===== Section Titles ===== */
h2 {
  font-size: 2rem;
  color: #bf0d1c;
  position: relative;
  margin-bottom: 1.5rem;
}

h2::after {
  content: "";
  display: block;
  width: 80px;
  height: 4px;
  background: #735290;
  border-radius: 2px;
  margin-top: 10px;
}

/* ===== Subtitles ===== */
h3 {
  color: #735290;
  font-size: 1.6rem;
  border-bottom: 2px solid #bf0d1c;
  padding-bottom: 0.4rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

/* ===== Videos ===== */
.video-wrapper {
  border-radius: 20px;
  overflow: hidden;
  margin-top: 1rem;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.video-wrapper video {
  width: 100%;
  height: auto;
  border-radius: 20px;
  transition: transform 0.3s ease;
}

.video-wrapper video:hover {
  transform: scale(1.02);
}

/* ===== Gallery Images ===== */
.gallery img {
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery img:hover {
  transform: scale(1.08) rotate(1deg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

/* ===== Back Button ===== */
.back-button a {
  background: linear-gradient(135deg, #bf0d1c, #735290);
  color: #fff;
  padding: 12px 28px;
  border-radius: 15px;
  font-weight: bold;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

.back-button a:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

/* ===== GitHub Link ===== */
.github-link a {
  background: linear-gradient(135deg, #735290, #bf0d1c);
  color: #fff;
  font-weight: 700;
  padding: 14px 30px;
  border-radius: 15px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

.github-link a:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

/* ===== Footer ===== */
footer {
  background: linear-gradient(135deg, #bf0d1c, #735290);
  color: #fff;
  font-style: italic;
  padding: 3rem 1rem;
  border-radius: 15px;
  box-shadow: 0 -5px 30px rgba(0, 0, 0, 0.2);
}

/* ===== Lightbox Styling ===== */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 25px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);
}

/* ===== Photo Row Layouts ===== */
.photo-triple,
.photo-pair {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.photo-triple img {
  flex: 1 1 calc(33% - 1rem);
  max-width: 32%;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.photo-pair img {
  flex: 1 1 calc(50% - 1rem);
  max-width: 48%;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.photo-triple img:hover,
.photo-pair img:hover {
  transform: scale(1.05) rotate(1deg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

/* ===== Section Hover Pop ===== */
section:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 25px 45px rgba(0, 0, 0, 0.18);
}

/* ===== Lightbox Upgrade ===== */
.lightbox img {
  border-radius: 25px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  transform: scale(1);
  transition: transform 0.3s ease;
}

.lightbox img:hover {
  transform: scale(1.03);
}

/* ===== Buttons Hover Lift ===== */
.back-button a,
.github-link a {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.back-button a:hover,
.github-link a:hover {
  transform: translateY(-4px) scale(1.06);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
}

/* ===== Section Titles Pop ===== */
h2 {
  position: relative;
  transition: all 0.4s ease;
}

h2:hover {
  color: #900a18;
}

h2::after {
  transition: all 0.4s ease;
}

h2:hover::after {
  width: 100px;
  background: #bf0d1c;
}

/* ===== Responsive / Mobile Tweaks ===== */
@media (max-width: 768px) {
  /* Header */
  header {
    padding: 2rem 1rem 1.5rem;
    border-radius: 15px;
  }

  header h1 {
    font-size: 2rem; /* smaller for mobile */
    line-height: 1.2;
  }

  header .subheading,
  header .tagline {
    font-size: 1.1rem;
  }

  /* Hero Section */
  .hero h1 {
    font-size: 2.2rem;
  }
  .hero p {
    font-size: 1.1rem;
  }

  /* Section adjustments */
  section {
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 15px;
  }

  /* Section Titles */
  h2 {
    font-size: 1.6rem;
  }

  h3 {
    font-size: 1.3rem;
  }

  /* Bottom cards */
  .bottom-cards {
    flex-direction: column;
    gap: 1.5rem;
  }

  /* Projects grid */
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  /* Contact grid */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }

  /* Video wrapper */
  .video-wrapper {
    max-height: 350px;
  }

  /* Gallery Images */
  .gallery img {
    max-width: 100%;
    height: auto;
  }

  /* Buttons */
  .back-button a,
  .github-link a,
  .btn {
    padding: 10px 20px;
    font-size: 0.95rem;
  }
}
