/* Category Hero Section */
.category-hero {
  padding: 200px 20px 60px 20px;
  background-color: black;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 350px;
}

.category-hero .container {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  width: 100%;
}

.back-link {
  display: inline-block;
  color: #4a9eff;
  text-decoration: none;
  font-size: 1rem;
  margin-bottom: 20px;
  transition: color 0.3s ease;
}

.back-link:hover {
  color: #00d4ff;
}

.category-hero h1 {
  font-size: 48px;
  color: #f0f0f0;
}

/* Mobile styles for Hero */
@media (max-width: 716px) {
  .category-hero {
    padding: 120px 20px 40px 20px;
    min-height: 250px;
  }

  .category-hero h1 {
    font-size: 2rem;
  }
}

/* Projects Section */
.projects {
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  padding: 60px 20px;
}

/* Project Cards */
.card-container {
  max-width: 1800px;
  margin: 0 auto;
  /* padding: 60px 20px; */
  display: flex;
  flex-direction: column;
}

.card-footer {
  margin-top: 60px;
  padding-top: 60px;
  border-top: 1px solid #6d6d6d;
  /* margin: auto; */
}

.back-to-top {
  text-align: center;
  /* margin: auto; */
}

.project-card {
  /* max-width: 1800px; */
  margin: 0 auto;
  width: 100%;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: stretch;
  gap: 30px;
  padding: 30px;
}

.project-description {
  flex: 1;
  min-width: 0;
}

.project-card h2 {
  font-size: 30px;
  font-weight: bold;
  color: #333;
  margin: 0;
}

.project-card p {
  font-size: 19px;
  color: #555;
  margin: 10px 0 0 0;
  line-height: 1.6;
}

.project-description h3 {
  font-size: 18px;
  color: #333;
  margin: 20px 0 15px 0;
  font-weight: 600;
}

.project-description ul {
  list-style: disc;
  padding-left: 20px;
  margin: 0;
}

.project-description li {
  font-size: 18px;
  color: #555;
  margin: 8px 0;
  line-height: 1.6;
}

.read-more-link {
  display: inline-block;
  margin-top: 8px;
  color: #4a9eff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.read-more-link:hover {
  color: #0080ff;
  text-decoration: underline;
}

.images-container {
  width: 60%;
  height: 100%;
  flex-shrink: 0;
  /* border-radius: 8px; */
  overflow: hidden;
}

.images-container img {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  object-fit: cover;
}

.image-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
}

.thumbnails {
  margin-top: 12px;
}

.image-controls {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.gallery-prev,
.gallery-next {
  border: none;
  background-color: #164145;
  color: #fff;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
}

.gallery-prev:focus-visible,
.gallery-next:focus-visible {
  outline: 2px solid #333;
  outline-offset: 2px;
}

.thumbnails ul {
  display: flex;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}

.thumbnails li {
  flex: 0 0 auto;
}

.thumbnails img {
  width: 72px;
  height: 48px;
  object-fit: cover;
  border-radius: 6px;
  display: block;
  cursor: pointer;
  border: 2px solid transparent;
}

.thumbnails img.is-active {
  border-color: #333;
}

@media (max-width: 1200px) {
  .project-card {
    flex-direction: column;
  }

  .images-container {
    width: 100%;
    order: 1;
  }

  .project-description {
    order: 2;
  }

  .image-navigation {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .thumbnails {
    margin-top: 8px;
  }

  .thumbnails ul {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .thumbnails img {
    width: 62px;
    height: 42px;
  }

  .image-controls {
    width: 100%;
    margin-top: 0;
    justify-content: center;
  }

  .gallery-prev,
  .gallery-next {
    min-width: 86px;
    padding: 10px 14px;
    font-size: 16px;
  }

  .image-holder {
    touch-action: pan-y;
  }
}
