body {
  /*
  background: linear-gradient(
    335deg,
    var(--med-pink) 10% 30%,
    var(--dark-green) 40% 60%,
    var(--blue) 70% 100%
  );
  */
  background-color: var(--med-pink);
}

.service-section {
  display: flex;
  padding: 1rem;
  gap: 40px;
  margin-bottom: 2rem;
  align-items: flex-start;
  border-radius: 20px;
  box-shadow: 0 15px 5px rgba(0, 0, 0, 0.1);
}

.service-section:nth-child(even) {
  flex-direction: row-reverse;
}

.service-card {
  display: flex;
  gap: 40px;
  margin-bottom: 1.5rem;
  align-items: flex-start;

  padding: 1rem;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 107, 157, 0.1);
}

.carousel-container {
  flex: 1;
  position: relative;
  align-self: center;
  border-radius: 15px;
  overflow: hidden;
  max-width: 500px;
  box-shadow: 0 15px 5px rgba(0, 0, 0, 0.1);
  /*padding: 0.3rem;*/
  background: #5e5e5e54;
  /*background: var(--opaque-white);*/
}

.carousel {
  position: relative;
  width: 100%;
  height: 350px;
  overflow: hidden;
  border-radius: 10px 10px 0 0;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
  height: 100%;
}

.carousel-slide {
  min-width: 100%;
  height: 100%;
  position: relative;
  cursor: pointer;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.carousel-slide:hover img {
  transform: scale(1.05);
}

.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  color: #333;
  transition: all 0.3s ease;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-nav:hover {
  background: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.carousel-prev {
  left: 0.5rem;
}

.carousel-next {
  right: 0.5rem;
}

/* Carousel icons/telltales */
.icon.arrow-left::before {
  content: "";
  display: inline-block;
  margin-right: 4px;
  margin-top: 5px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 12px solid #333;
}

.icon.arrow-right::before {
  content: "";
  display: inline-block;
  margin-left: 4px;
  margin-top: 5px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid #333;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 20px;
  background: transparent;
  border-radius: 0 0 10px 10px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background: var(--black);
  transform: scale(1.3);
}

.service-content {
  flex: 1;
  padding: 20px;
}

.service-title {
  font-size: 2.2rem;
  color: #333;
  margin-bottom: 20px;
  font-weight: 600;
}

.service-description {
  font-size: 1.1rem;
  line-height: 1.6rem;
  color: #555;
  margin-bottom: 0.7rem;
}

.service-text {
  max-height: 16rem;
  overflow: hidden;
  position: relative;
  margin-bottom: 1rem;
  mask-image: linear-gradient(to bottom, black 60%, transparent 100%);

  mask-repeat: no-repeat;
  mask-size: 100% 100%;
  mask-position: top;
  transition: max-height 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    mask-size 2s cubic-bezier(0.25, 1, 0.5, 1);
}

.service-text::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  opacity: 1;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.service-text.expanded {
  max-height: 800px;
  mask-size: 100% 200%;
}

.service-text.expanded::after {
  opacity: 0;
}

/* Arrow rotation for learn-more button */
.learn-more .circle .icon.arrow {
  transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.learn-more .button-text {
  transition: all 0.3s ease;
}

.learn-more .circle .icon.arrow::before {
  top: -0.4rem;
  right: -0.09rem;
  width: 0.625rem;
  height: 0.625rem;
  transform: rotate(135deg);
}

.learn-more-wrap {
  padding: 0;
}

.learn-more-wrap .circle {
  width: 3rem;
  transition: width 0.3s ease, background-color 0.3s ease;
  background-color: var(--pink);
}

.learn-more-wrap .icon.arrow {
  transition: transform 0.3s ease;
  background-color: var(--pink);
}

.learn-more-wrap.expanded .icon.arrow::before {
  top: -0.5rem;
  right: 0.3rem;
  width: 0.625rem;
  height: 0.625rem;
}

.learn-more-wrap.expanded .circle {
  width: 100%;
}

.learn-more-wrap.expanded .icon.arrow {
  transform: rotate(-180deg);
}

.learn-more-wrap.expanded .button-text {
  color: #fff;
}

/* Lightbox Modal */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 1000;
  backdrop-filter: blur(5px);
}

.lightbox.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 24px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
  left: -80px;
}

.lightbox-next {
  right: -80px;
}

.lightbox-close {
  position: absolute;
  top: -50px;
  right: -50px;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 24px;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.lightbox-counter {
  position: absolute;
  bottom: -50px;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  font-size: 18px;
  font-weight: 500;
  padding: 10px 20px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 20px;
  backdrop-filter: blur(10px);
}

/* Touch gestures for mobile */
.touch-area {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
}

/* Responsive Design */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
    margin-bottom: 30px;
  }

  .service-section {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
  }

  .service-section:nth-child(even) {
    flex-direction: column;
  }

  .carousel {
    height: 250px;
  }

  .service-title {
    font-size: 1.8rem;
  }

  .lightbox-nav {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }

  .lightbox-prev {
    left: -60px;
  }

  .lightbox-next {
    right: -60px;
  }

  .lightbox-close {
    top: -40px;
    right: -40px;
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .service-text {
    max-height: 12rem;
  }

  .lightbox-prev {
    left: 10px;
  }

  .lightbox-next {
    right: 10px;
  }

  .lightbox-close {
    top: 10px;
    right: 10px;
  }

  .lightbox-counter {
    bottom: 10px;
  }
}

@media (hover: hover) and (pointer: fine) {
  .learn-more:hover .circle {
    width: 100%;
  }

  .learn-more:hover .button-text {
    color: white;
  }

  .learn-more:hover .circle .icon.arrow {
    transform: translateY(0.5rem);
  }
  
  .learn-more-wrap.expanded:hover .icon.arrow {
    transform: translateY(-0.5rem) rotate(180deg);
  }
}
