.services-container {
  height: calc(var(--vh) * 200);
  position: relative;
  color: white;
  width: 100vw !important;
}

.hero-services {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 50%;
  flex-direction: column;
  background: linear-gradient(
    0deg,
    #181818,
    #2b2b2bc9
  ); /* almost black to grey */
}

.headline {
  display: flex;
  justify-content: center;
  column-gap: 2%;
  width: 90%;
  font-size: 5vw;
}

.headline .first-title{
  text-align: right !important;
  display: flex;
}

.services{
  display: flex;
  flex-direction: column;
}

.subhead {
  display: flex;
}

.inactive {
  opacity: 0.5;
  font-weight: 700;
}

.service-active {
  font-weight: 700;

  opacity: 1 !important;
  text-decoration: underline;
  text-decoration-color: #6b5bff; /* your blue-purple accent */
}

.service-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 500;
  color: #ffffff; /* purple-blue-ish */
  border: 2px solid #ffffff;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  overflow: hidden;
}

.service-button:hover {
  background: #4a00e0;
  color: white;
  box-shadow: 0 8px 20px rgba(74, 0, 224, 0.3);
  transform: translateY(-2px);
}

.service-button .material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 48;
  transition: transform 0.3s ease;
}

.service-button:hover .material-symbols-outlined {
  transform: translateY(4px);
}

.service-list {
  display: flex;
  justify-content: space-evenly;
  width: 100%;
  height: 50%;
  background-color: rgb(24, 24, 24);
}

.service-box {
  position: relative;
  width: 25%;
  height: 70%;
  border: 2px solid rgb(124, 24, 255);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease;
}

/* Background video */
.service-box .bg-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;

  filter: blur(5px); /* initial strong blur */
  transform: scale(1); /* normal size */
  transition: filter 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.service-box:hover .bg-video {
  filter: blur(1px); /* reduce blur smoothly */
  transform: scale(1.05); /* subtle zoom-in */
}

/* Overlay */
.service-box .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1;
  transition: background 0.4s ease; /* smooth fade */
}

/* Text container at bottom */
.service-box .text-container {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 15px;
  z-index: 2;
  color: #fff;
}

/* Title always visible */
.service-box .card-title {
  font-size: 2rem;
  font-weight: 600;
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7); /* subtle shadow for readability */
}

/* Extra text hidden by default */
.service-box .card-text {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  font-size: 0.9rem;
  margin-top: 8px;
}

/* Show extra text on hover */
.service-box:hover .card-text {
  opacity: 1;
  transform: translateY(0);
}

/* Subtle lift */
.service-box:hover {
  transform: translateY(-2px);
}

.service-box:hover .overlay {
  background: rgba(77, 0, 107, 0.2);
}

/* Tablet (≤1024px) */
@media (max-width: 1024px) {
  .headline{
    width: 98%;
    font-size: 7vw !important;
  }

  .service-list {
    flex-wrap: wrap; /* allow items to wrap to new row */
    justify-content: center;
    gap: 1rem;
    height: 50%; /* let height adjust naturally */
    padding: 1rem;
  }

  .service-box {
    width: 45%; /* 2 per row */
    height: 250px;
  }

  .service-box .card-title {
    font-size: 1.4rem;
  }
}

/* Mobile (≤768px) */
@media (max-width: 768px) {
  .service-list {
    flex-direction: column; /* stack vertically */
    align-items: center;
  }

  .service-box {
    width: 90%; /* full width with padding */
    height: 220px;
  }

  .service-box .card-title {
    font-size: 1.2rem;
  }

  .service-box .card-text {
    font-size: 0.85rem;
  }
}

/* Small Mobile (≤480px) */
@media (max-width: 480px) {
  .service-box {
    height: 180px;
  }

  .service-box .card-title {
    font-size: 1rem;
  }

  .service-box .card-text {
    font-size: 0.8rem;
  }
}
