/*
Theme Name: Avada Child
Description: Child theme for Avada theme
Author: ThemeFusion
Author URI: https://theme-fusion.com
Template: Avada
Version: 1.0.0
Text Domain:  Avada
*/

.mg-gallery-container {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.mg-main-slider {
  width: 100%;
  position: relative;
}

.mg-main-slider img {
  width: 100%;
  border-radius: 10px;
}

/* Arrows */
.mg-button-prev,
.mg-button-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  cursor: pointer;
  font-size: 26px;
  padding: 10px 16px;
  background: rgba(0,0,0,0.6);
  color: #fff;
  border-radius: 50%;
}

.mg-button-prev { left: 10px; }
.mg-button-next { right: 10px; }

.mg-button-prev:hover,
.mg-button-next:hover {
  background: rgba(0,0,0,0.9);
}

/* Thumbnails bottom */
.mg-thumb-row {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.mg-thumb-item img {
  width: 100px;
  height: 70px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  opacity: 0.6;
  transition: .3s;
}

.mg-thumb-item.active img,
.mg-thumb-item:hover img {
  opacity: 1;
  border: 2px solid #000;
}
.nf-form-content {
	margin-top: 15px !important;
}

/* =========================
   GALLERY GRID LAYOUT
========================= */
.gallery-wrapper {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 15px;
  margin-bottom: 30px;
  position: relative;
  z-index: 1;
}

.gallery-left img,
.gallery-right img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
}

.gallery-left {
  height: 420px;
}

.gallery-right {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 10px;
  height: 420px;
}
.page-id-8658 .gallery-left{
	height: auto !important;
}
.more-photos {
  position: relative;
  cursor: pointer;
  z-index: 2;
}

.more-photos img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
}

.more-photos span {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  padding: 6px 14px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
}

/* =========================
   LIGHTBOX — FIXED Z-INDEX
========================= */
#lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: #1e1e1e;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  z-index: 999999999 !important;  /* Highest priority */
  padding: 20px;
}

#lightbox-img {
  max-width: 80%;
  max-height: 75%;
  border-radius: 6px;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
  position: relative;
  z-index: 999999999;
}
/* CLOSE BUTTON FIX */
/* FORCE SHOW CLOSE BUTTON */
#lightbox .close {
    all: unset !important;           /* Remove Avada conflicts */
    position: absolute !important;
    top: 10px !important;
    right: 30px !important;
    z-index: 999999999 !important;
    font-size: 42px !important;
    color: #fff !important;
    cursor: pointer !important;
    display: block !important;
    opacity: 1 !important;
    line-height: 1 !important;
}

/* Prevent Avada from hiding text inside span.close */
#lightbox .close::before,
#lightbox .close::after {
    display: none !important;
}


.close,
.prev,
.next {
  position: absolute;
  color: #fff;
  font-size: 36px;
  cursor: pointer;
  padding: 10px;
  user-select: none;
  z-index: 999999999 !important; /* Force above all */
}

.close { top: 20px; right: 30px; }
.prev { top: 50%; left: 30px; transform: translateY(-50%); }
.next { top: 50%; right: 30px; transform: translateY(-50%); }

/* =========================
   THUMBNAILS
========================= */
.thumbs {
  display: flex;
  gap: 8px;
  margin-top: 20px;
  overflow-x: auto;
  padding: 10px;
  max-width: 90%;
  z-index: 999999999 !important;
}

.thumbs img {
  width: 80px;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.6;
  transition: 0.2s;
}

.thumbs img:hover,
.thumbs img.active {
  opacity: 1;
  border: 2px solid #fff;
}

/* =========================
   PREVENT PAGE OVERLAY BEHIND LIGHTBOX
========================= */
body.lightbox-open {
  overflow: hidden;
  position: relative;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
  .gallery-wrapper {
    grid-template-columns: 1fr;
  }

  .gallery-left,
  .gallery-right {
    height: auto;
  }

  .gallery-right {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }

  #lightbox-img {
    max-width: 95%;
    max-height: 70%;
  }

  .prev,
  .next {
    font-size: 28px;
  }
	#lightbox .close{
		top:100px !important;
	}
}

.info-box {
    background: #f3f3f3;
    padding: 5px 20px;
    border-radius: 14px;
    display: inline-block;
    margin-right: 15px;
    /*min-width: 160px;*/
	margin-bottom:15px;
}

.info-title {
    display: block;
    font-size: 14px;
    color: #666;
}

.info-value {
    display: block;
    font-size: 16px;
    font-weight: 600;
    /*margin-top: 4px;*/
    color: #111;
}
textarea{
	padding: 15px !important;
}
.nf-field-label label,.nf-form-fields-required{
	display: none !important;
}
