/* ===== Smooth Scrolling ===== */
html {
  scroll-behavior: smooth;
}

/* ===== Global Styles ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  background: #141414; /* Netflix dark background */
  color: #fff;
}

h1, h2, h3 {
  color: #fff;
}

a {
  text-decoration: none;
  color: #e50914; /* Netflix red accent */
  transition: 0.3s;
}

a:hover {
  color: #ff3d3d;
}

section {
  padding: 80px 20px;
  max-width: 1200px;
  margin: auto;
}

/* ===== Hero Section ===== */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 100vh;
  background: linear-gradient(to bottom, #141414 0%, #1c1c1c 100%);
}

.hero-content {
  max-width: 700px;
}

.hero .profile-pic {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  margin-bottom: 20px;
  border: 4px solid #e50914;
}

.hero h1 span {
  color: #e50914;
}

.btn {
  display: inline-block;
  margin-top: 20px;
  padding: 14px 28px;
  background: #e50914;
  color: #fff;
  border-radius: 5px;
  font-weight: 600;
  transition: 0.3s;
}

.btn:hover {
  background: #ff3d3d;
}

/* ===== Services Section ===== */
#services {
  background: #1c1c1c;
  text-align: center;
  border-radius: 10px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.service-card {
  background: #252525;
  padding: 30px;
  border-radius: 10px;
  transition: transform 0.3s, box-shadow 0.3s;
}

.service-card i {
  font-size: 2.2rem;
  margin-bottom: 15px;
  color: #e50914;
}

.service-card:hover {
  transform: translateY(-8px) scale(1.05);
  box-shadow: 0 10px 25px rgba(229, 9, 20, 0.4);
  background: #2a2a2a;
}

/* ===== Skills Section ===== */
#skills {
  background: #1c1c1c;
  text-align: center;
  padding: 60px 20px;
  border-radius: 10px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 25px;
  margin-top: 30px;
}

.skill {
  text-align: left;
}

.skill h3 {
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.skill-bar {
  width: 100%;
  height: 20px;
  background: #252525;
  border-radius: 10px;
  overflow: hidden;
}

.skill-fill {
  width: 0;
  height: 100%;
  background: #e50914;
  border-radius: 10px;
  transition: width 1.5s ease-in-out;
}

/* ===== Projects Section ===== */
#projects {
  text-align: center;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 25px;
  margin-top: 30px;
}

.project-card {
  display: block;
  background: #252525;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}

.project-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.3s;
}

.project-card h3 {
  padding: 15px;
  font-weight: 600;
  color: #e50914;
}

.project-card:hover {
  transform: translateY(-8px) scale(1.05);
  box-shadow: 0 12px 25px rgba(229, 9, 20, 0.5);
}

.project-card:hover img {
  transform: scale(1.1);
}

/* ===== Certificates Section ===== */
#certificates {
  text-align: center;
  padding: 60px 20px;
  background: #161b22;
  border-radius: 10px;
}

.certificates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.certificate-card {
  background: #1f2937;
  border-radius: 10px;
  overflow: hidden;
  padding: 20px;
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
  border: 2px solid transparent;
}

.certificate-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 5px;
  margin-bottom: 15px;
}

.certificate-card h3 {
  color: #fff;
  font-size: 1rem;
  transition: color 0.3s;
}

.certificate-card:hover {
  transform: translateY(-8px) scale(1.05);
  box-shadow: 0 10px 20px rgba(229, 9, 20, 0.3); /* Netflix red glow */
  border-color: #e50914; /* Netflix red border */
}

.certificate-card:hover h3 {
  color: #e50914; /* Netflix red text */
}

/* ===== Contact Section ===== */
#contact {
  background: #1c1c1c;
  text-align: center;
  border-radius: 10px;
  padding: 60px 20px;
}

#contact a {
  color: #e50914;
  font-weight: bold;
}

#contact a:hover {
  color: #ff3d3d;
}

/* ===== Footer ===== */
footer {
  text-align: center;
  padding: 20px;
  background: #141414;
  color: #aaa;
  margin-top: 40px;
}

/* ===== Navbar ===== */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(20,20,20,0.95);
  backdrop-filter: blur(8px);
  padding: 15px 40px;
  z-index: 1000;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: auto;
}

.logo {
  color: #fff;
  font-size: 1.6rem;
  font-weight: 700;
}

.logo span {
  color: #e50914;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 25px;
}

.nav-links li a {
  color: #fff;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-links li a:hover,
.nav-links li a.active {
  color: #e50914;
}

/* ===== Hamburger Menu ===== */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: #fff;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Mobile Styles */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 70px;
    right: -100%;
    background: rgba(20,20,20,0.95);
    height: calc(100vh - 70px);
    width: 220px;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 50px;
    gap: 25px;
    transition: right 0.3s ease;
  }

  .nav-links.active {
    right: 0;
  }

  .hamburger {
    display: flex;
  }
}

/* ===== Back to Top Button ===== */
#backToTop {
  position: fixed;
  bottom: 40px;
  right: 40px;
  display: none;
  background: #e50914;
  color: #fff;
  border: none;
  padding: 12px 16px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  transition: opacity 0.4s, transform 0.3s;
  z-index: 1000;
}

#backToTop:hover {
  background: #ff3d3d;
  transform: scale(1.1);
}

/* ===== Scroll Animations ===== */
section {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.7s ease-out;
}

section.scrolled {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Card Scroll Animations ===== */
.service-card, .project-card {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-out;
}

.service-card.card-scrolled, .project-card.card-scrolled {
  opacity: 1;
  transform: translateY(0);
}
