:root {
  --booking-widget-buffer: 50px;
}

/* Main Banner */
.main-banner {
  position: relative;
}

.main-banner .banner {
  width: 100%;
  height: auto;
  max-height: 100vh;
  object-fit: cover;
  object-position: center;
}

.main-banner-heading {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  max-width: 100vw;
  padding-left: 25vw;
  padding-right: 25vw;
  box-sizing: border-box;
  text-align: center;
}

.main-banner-heading h1 {
  color: #fff;
  font-size: 2.5rem;
  line-height: 3.875rem;
}

@media (max-width: 767px) {
  .main-banner-heading {
    padding-left: 15vw;
    padding-right: 15vw;
  }

  .main-banner-heading h1 {
    font-size: 1.75rem;
    line-height: 1.4;
  }
}

.main-banner .arrow-down {
  position: absolute;
  bottom: 2.25rem;
  left: 50%;
  transform: translateX(-50%);
  width: 2.5rem;
  height: 2.5rem;
}

/* Tabs */
.grid-wrapper {
  max-width: 120rem;
  /* 1920px */
  margin: 0 auto;
  padding: 3.5rem 0 0;
  
  @media (min-width: 768px) {
    padding: 4.5rem 0 0;
  }
}

.language {
  padding-left: 12px;
}

.language a {
  color: currentColor;
}

.tabs {
  display: flex;
  gap: 1rem;
  overflow: auto;
  padding: 2.5rem 1.25rem 1.25rem;
  margin-bottom: 1.875rem;
  align-items: center;

  @media (min-width: 1279px) {
    justify-content: center;
  }
}

.tab {
  flex: 0 0 auto;
}

.tab.active {
  background-color: #212121;
  color: #fff;
  cursor: pointer;
}

.tab-content {
  display: grid;
  grid-gap: 0.375rem;
  grid-template-columns: repeat(1, 1fr);

  @media (min-width: 768px) {
    grid-template-columns: repeat(3, 1fr);
  }
}

.mosaic .tab-content {
  @media (min-width: 768px) {
    grid-template-columns: repeat(12, 1fr);
  }
}

.tab-img {
  touch-action: manipulation;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;

  @media (max-width: 767px) {
    height: auto;
    width: 100%;
  }
}

.mosaic .tab-item:nth-child(1),
.mosaic .tab-item:nth-child(2),
.mosaic .tab-item:nth-child(3),
.mosaic .tab-item:nth-child(10),
.mosaic .tab-item:nth-child(11),
.mosaic .tab-item:nth-child(12),
.mosaic .tab-item:nth-child(15),
.mosaic .tab-item:nth-child(16),
.mosaic .tab-item:nth-child(17) {
  @media (min-width: 768px) {
    grid-column: span 4;
  }
}

.mosaic .tab-item:nth-child(4),
.mosaic .tab-item:nth-child(5),
.mosaic .tab-item:nth-child(6),
.mosaic .tab-item:nth-child(7) {
  @media (min-width: 768px) {
    grid-column: span 3;
  }
}

.mosaic .tab-item:nth-child(8),
.mosaic .tab-item:nth-child(9),
.mosaic .tab-item:nth-child(13),
.mosaic .tab-item:nth-child(14) {
  @media (min-width: 768px) {
    grid-column: span 6;
  }
}

.mosaic .tab-item:nth-child(18),
.mosaic .tab-item:nth-child(19),
.mosaic .tab-item:nth-child(20),
.mosaic .tab-item:nth-child(21) {
  @media (min-width: 768px) {
    grid-column: span 3;
  }
}

/* About us */
.about-us {
  text-align: center;
}

.about-us .heart {
  margin: 2.125rem auto;
}

.about-us p {
  max-width: 51.25rem;
  margin: 1.875rem auto 0;
  font-size: 1.125rem;
  line-height: 1.875rem;

  @media (max-width: 767px) {
    font-size: 1rem;
  }
}

.photos .wrapper {
    padding-top: 2rem !important;
}

/* Amenities */
.amenities {
  background-color: #f5f5f5;
}

#amenities .wrapper {
  padding-top: 2rem !important;
}

.amenities .sub-title {
  text-align: center;
  font-size: 1.125rem;
  line-height: 1.875rem;
  font-weight: 400;
  margin-top: 1rem;

  @media (max-width: 767px) {
    font-size: 1rem;
  }
}

.amenities .amenities-list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2.25rem;
  list-style: none;
  margin-top: 2.75rem;

  @media (max-width: 767px) {
    grid-template-columns: repeat(2, 1fr);
  }

  @media (min-width: 768px) and (max-width: 1279px) {
    grid-template-columns: repeat(3, 1fr);
  }
}

.amenities .amenities-item {
  display: flex;
  align-items: center;
  gap: 1rem;

  @media (max-width: 767px) {
    flex-direction: column;
    text-align: center;
  }
}

/* Booking banner */
.booking {
  background: url("../images/booking-banner.jpg") no-repeat center center;
  background-size: cover;

  @media (max-width: 767px) {
    background: url("../images/booking-banner-mobile.jpg") no-repeat center center;
    background-size: cover;
  }

  @media (min-width: 768px) and (max-width: 1023px) {
    background: url("../images/booking-banner-tablet.jpg") no-repeat center center;
    background-size: cover;
  }
}

.booking .wrapper {
  color: #fff;
  font-size: 1.25rem;
  line-height: 1.875rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  @media (max-width: 767px) {
    padding-top: 3.5rem;
  }
}

.booking .button {
  padding: 0 3.25rem;
  min-height: 3.5rem;
  margin: 0 auto 0.75rem;
  display: block;
}

.booking-info {
  padding-top: 2rem;
}

.booking-info a {
  color: #fff;
}

.booking-info .phone {
  text-decoration: none;
  font-size: 2.25rem;
  line-height: 1.2;
  margin: 2.125rem 0;
  display: inline-block;
}

.booking-popup {
  position: relative;
  padding-top: 0.625rem;
}

.booking-popup:before {
  content: "";
  position: absolute;
  top: 0.25rem;
  left: 50%;
  margin-left: -0.563rem;
  width: 0;
  height: 0;
  border-top: 1.125rem solid #fff;
  border-right: 1.125rem solid transparent;
  transform: rotate(45deg);
}

.booking-popup-wrapper {
  width: 100%;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  border-radius: 12px;
  margin-top: 0.75rem;
  margin-bottom: 1.25rem;
  pointer-events: none;
  transition: max-height .35s ease, opacity .25s ease;
}

.booking-popup-wrapper.active {
  opacity: 1;
  max-height: 200rem;
  pointer-events: auto;
}

.booking-scroll {
  max-height: calc(100vh - 6rem);
  overflow-y: auto;
  overflow-x: hidden; /* повернуто hidden */
  -webkit-overflow-scrolling: touch;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 0.5rem 1.25rem rgba(0,0,0,0.15);
  padding: 0 0.5rem;
  max-width: 90vw;
  width: 100%;
  box-sizing: border-box;
  margin-left: auto;
  margin-right: auto;
  scrollbar-gutter: stable both-edges;
  overscroll-behavior: auto;
}

/* (reverted stricter horizontal scroll overrides) */

@media (min-width: 768px) {
  .booking-scroll { max-height: calc(100vh - 7.5rem); }
}
@media (min-width: 1024px) {
  .booking-scroll { width: clamp(62rem, 60vw, 72rem); max-width: 72rem; max-height: 75vh; }
}

.booking-popup, .booking-popup * { box-sizing: border-box; }
.booking-popup { overflow-x: hidden; }

.booking-scroll iframe, .booking-popup iframe {
  display: block;
  width: 100% !important;
  max-width: 100%;
  border: none;
}

.contacts .wrapper {
  flex-basis: 50%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

@media (min-width: 1024px) {
  .contacts { display: flex; align-items: stretch; padding: 0 7.5rem; gap: 2.5rem; }
  .contacts .wrapper, .contacts .map { flex: 1 1 50%; max-width: 50%; }
  .contacts .map iframe { height: 100%; min-height: 550px; }
}

.contacts .info {
  margin-top: 1.5rem;
  font-size: 1.125rem;
  line-height: 1.375rem;
}

.contacts .info h3 {
  font-size: 0.875rem;
  line-height: 1.875rem;
  font-weight: 400;
}

.contacts .info a {
  color: #212121;
  text-decoration: none;
}

.contacts .info a:hover {
  @media (hover: hover) {
    text-decoration: underline;
  }
}

.contacts .icons {
  display: flex;
  justify-content: center;
  gap: 0.813rem;
  margin-top: 2.125rem;
}

.contacts .icons a {
  transition: all 0.3s ease;
}

.contacts .icons a:hover {
  @media (hover: hover) {
    opacity: 0.7;
  }
}

.contacts .icons img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.map {
  flex-basis: 50%;
}

/* Additional Pages */
.additional-pages {
  background: url("../images/main-banner.jpg") no-repeat center center;
  background-size: cover;

  @media (max-width: 767px) {
    background: url("../images/main-banner-mobile.jpg") no-repeat center center;
    background-size: cover;
  }

  @media (min-width: 768px) and (max-width: 1023px) {
    background: url("../images/main-banner-tablet.jpg") no-repeat center center;
    background-size: cover;
  }
}

.additional-pages .pages {
  color: #fff;
  text-align: center;
  display: flex;
  margin: 0 auto;
  list-style: none;
  justify-content: space-around;

  @media (max-width: 767px) {
    flex-direction: column;
    align-items: center;
    gap: 3rem;
  }
}

.lightbox {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
}

.lightbox.active {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: auto;
}

.lightbox-content {
  max-width: 80%;
  max-height: 80%;
  margin: auto;
  display: block;

  @media (max-width: 768px) {
    max-width: 100%;
    max-height: 100%;
  }
}

.close {
  position: absolute;
  top: 20px;
  right: 35px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 2000;
}

.prev,
.next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #fff;
  font-size: 40px;
  user-select: none;
  padding: 16px;

  @media (max-width: 768px) {

    top: auto;
    bottom: 20px;
    transform: none;
  }
}

.prev {
  left: 10px;
}

.next {
  right: 10px;
}


.lightbox-content-wrapper {
  position: relative;
  display: inline-block;
  max-width: 100%;
  max-height: 100%;
}


#loader {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border: 8px solid #f3f3f3;
  border-top: 8px solid #2F2F2F;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  display: none;
  z-index: 9999;
  display: none;
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }

  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.lightbox-details-toggle {
  position: absolute;
  bottom: 0;
  right: 10%;
  margin: 0;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  padding: 10px 15px;
  border-radius: 5px;
  cursor: pointer;
  z-index: 2000;
  user-select: none;
  transition: background 0.3s ease;
}

.lightbox.loading .lightbox-details-toggle {
  display: none !important;
}

.lightbox-details-toggle:hover {
  background: rgba(0, 0, 0, 0.7);
}

.lightbox-details-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  z-index: 1500;
  font-size: 22px;

  @media (max-width: 768px) {
    font-size: 20px;
  }
}

.lightbox-details-content.active {
  display: flex;
}