.services {
  color: #fff;
}

.service-card {
  position: relative;
  height: 300px;
  border-radius: 15px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  transition: transform 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Hover zoom effect */
/* .service-card:hover {
  transform: scale(1.05);
} */

/* Show overlay if hovered (desktop) or active (mobile tap) */
.service-card.active .overlay {
  opacity: 1;
}


/* Title always visible */
.service-card .title {
  position: absolute;
  bottom: 20px;
  left: 20px;
  font-size: 1.3rem;
  font-weight: bold;
  color: #ffffff;
  z-index: 2;
  text-shadow: 0 2px 6px rgba(0,0,0,0.6);
}

/* Overlay with sub content (hidden by default) */
.service-card .overlay {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: rgba(0, 0, 0, 0.85);
  color: #ffffff;
  opacity: 0;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: opacity 0.4s ease;
  text-align: left;
}

.service-card:hover .overlay {
  opacity: 1;
}

.overlay h5 {
  font-size: 1.2rem;
  margin-bottom: 10px;
  color: #1363ff;
}

.overlay ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.overlay ul li {
  margin-bottom: 6px;
  font-size: 0.9rem;
}

/* 📱 Mobile adjustments */
@media (max-width: 768px) {
  .service-card {
    height: 220px; /* smaller cards */
  }

  .service-card .title {
    font-size: 1rem;
    bottom: 15px;
    left: 15px;
  }

  .overlay h5 {
    font-size: 1rem;
  }

  .overlay ul li {
    font-size: 0.8rem;
  }
}

/* 📱 Very small devices */
@media (max-width: 480px) {
  .service-card {
    height: 200px;
  }

  .service-card .title {
    font-size: 0.9rem;
    bottom: 10px;
    left: 10px;
  }

  .overlay h5 {
    font-size: 0.95rem;
  }

  .overlay ul li {
    font-size: 0.75rem;
  }
}