/* ===============================
   GLOBAL STYLING
=============================== */
body {
  background-color: #0d0d0d;
  color: #f8f9fa;
  font-family: "Poppins", sans-serif;
  margin: 0;
  padding: 0;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===============================
   NAVBAR
=============================== */
.navbar {
  background-color: #000;
  padding: 1.3rem 0;
  border-bottom: 1px solid #222;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.navbar-brand {
  font-size: 1.6rem;
  font-weight: 600;
  color: #f8f9fa;
  text-decoration: none;
}

.navbar-brand span {
  color: #00bfff;
}

.nav-links {
  display: flex;
  gap: 2.2rem;
  transition: all 0.3s ease;
}

.nav-links a {
  color: #f8f9fa;
  font-weight: 600;
  font-size: 1.08rem;
  text-decoration: none;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: #00bfff;
}

.nav-links a.active {
  color: #00bfff;
}


/* === HAMBURGER TOGGLE === */
.menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background-color: #f8f9fa;
  border-radius: 2px;
  transition: 0.3s;
}



/* ===============================
   HERO SECTION (Beranda)
=============================== */
.hero {
  text-align: center;
  padding: 8rem 1rem 5rem;
}

.hero h1 {
  font-size: 2.8rem;
  color: #f8f9fa;
  margin-bottom: 0;
}

.hero p {
  font-size: 1.2rem;
  line-height: 1.6rem;
  color: #d1d1d1;
  margin-bottom:1rem;
}

.btn-primary {
  background-color: #00bfff;
  color: #fff;
  padding: 0.7rem 1.5rem;
  border-radius: 3px;
  transition: 0.3s;
  border: none;
  cursor: pointer;
  display: inline-block;
}

.btn-primary:hover {
  background-color: #0099cc;
}

/* ===============================
   PROJECT CARDS (Index & Portofolio)
=============================== */
.wrapper{
    margin-top: 3rem;
}
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  padding: 1rem 0;
}

.project-card {
  background-color: #1a1a1a;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s;
}

.project-card:hover {
  transform: translateY(-5px);
}

.project-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.project-card .content {
  padding: 1rem 1.3rem 1.5rem; /* sedikit lebih rapat */
}

.project-card h3 {
  margin: 0.3rem 0;
  font-size: 1.25rem;
}

.project-card p {
  color: #bfbfbf;
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

/* ===============================
   ABOUT PAGE
=============================== */
.about {
  padding: 5rem 1rem;
}

.about .profile {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2rem;
}

.about .info {
  max-width: 600px;
}

/* ===============================
   BLOG PAGE
=============================== */
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding: 4rem 1rem;
}

.blog-card {
  background: #fff;
  color: #000;
  padding: 1rem 2rem 1.5rem;
  border-radius: 1rem;
}

.blog-card h2 {
  margin-bottom: 1rem;
}

.blog-card details summary {
  cursor: pointer;
  font-weight: 600;
  color: #00bfff;
}

/* ===============================
   CONTACT PAGE
=============================== */
.contact {
  padding: 5rem 1rem;
  text-align: center;
}

.contact form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 500px;
  margin: 2rem auto;
}

.contact input, .contact textarea {
  padding: 0.8rem;
  border-radius: 0.5rem;
  border: 1px solid #333;
  background-color: #1a1a1a;
  color: #fff;
}

.contact button {
  background-color: #00bfff;
  color: #fff;
  padding: 0.8rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
}

.contact button:hover {
  background-color: #0099cc;
}

/* ANIMATION */
/* === Fade-in animation === */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}


/* ===============================
   FOOTER
=============================== */
footer {
  text-align: center;
  padding: 2rem 0;
  color: #a1a1a1;
  font-size: 0.9rem;
}

/* === RESPONSIVE NAVBAR === */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 50px;
    right: 0;
    width: 100%;
    background: #0d0d0d;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem 0;
    display: none;
    z-index: 1000;
  }

  .nav-links.show {
    display: flex;
  }

  /* Animasi hamburger jadi X */
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }
}
