.slider {
  position: relative;
  width: 100%;
  height: 240px;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.slides {
  display: flex;
  transition: transform 0.6s ease-in-out;
  height: 240px;
}

.slides img {
  width: 100%;
  height: auto;
  max-height: 240px; /* prevents overflow */
  object-fit: cover;
  flex-shrink: 0;
  cursor: pointer;
}

/* Hover grid effect */
.slider:hover .slides {
  transform: none !important;
  flex-wrap: wrap;
  overflow-y: auto;
}

.slider:hover .slides img {
  width: 50%;
  height: auto;
}

.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 28px;
  color: white;
  cursor: pointer;
  padding: 10px;
  background: rgba(0,0,0,0.4);
  border-radius: 50%;
  user-select: none;
  transition: 0.3s;
}
.arrow:hover { background: rgba(0,0,0,0.7); }
.arrow.left { left: 10px; }
.arrow.right { right: 10px; }

.slider-dots {
  position: absolute;
  bottom: 12px;
  width: 100%;
  text-align: center;
}
.slider-dots span {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin: 0 3px;
  background: rgba(255,255,255,0.6);
  border-radius: 50%;
  cursor: pointer;
}
.slider-dots span.active {
  background: #fff;
  transform: scale(1.3);
}

/* Lightbox styles */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 12000;
}

.lightbox.active {
  visibility: visible;
  opacity: 1;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

.lightbox .close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 30px;
  color: white;
  cursor: pointer;
}

.lightbox .arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 40px;
  color: white;
  cursor: pointer;
  user-select: none;
  padding: 10px;
}

.lightbox .arrow.left { left: 20px; }
.lightbox .arrow.right { right: 20px; }

.lightbox .arrow:hover,
.lightbox .close:hover {
  color: #ffcc00;
}
