/* Hamburger Icon */
.xnav-icon {
  position: relative;
  z-index: 4;
  width: 26px;
  height: 21px;
  cursor: pointer;
}

.xnav-icon span {
  position: absolute;
  width: 50%;
  height: 3px;
  background: #2a1929;
  transition: all 0.2s ease-in-out;
}

.xnav-icon span {
  background: #222;
}

.xnav-icon span:nth-child(odd) {
  /* 1, 3, 5 */
  left: 0;
  border-radius: 5px 0 0 5px;
}

.xnav-icon span:nth-child(even) {
  /* 2, 4, 6 */
  left: 50%;
  border-radius: 0 5px 5px 0;
}

.xnav-icon span:nth-child(1),
.xnav-icon span:nth-child(2) {
  top: 0;
}

.xnav-icon span:nth-child(3),
.xnav-icon span:nth-child(4) {
  top: 9px;
}

.xnav-icon span:nth-child(5),
.xnav-icon span:nth-child(6) {
  top: 18px;
}

.xnav-open .xnav-icon span:nth-child(1),
.xnav-open .xnav-icon span:nth-child(6) {
  transform: rotate(45deg);
}

.xnav-open .xnav-icon span:nth-child(2),
.xnav-open .xnav-icon span:nth-child(5) {
  transform: rotate(-45deg);
}

.xnav-open .xnav-icon span:nth-child(1) {
  top: 5px;
  left: 2px;
}

.xnav-open .xnav-icon span:nth-child(2) {
  top: 5px;
  left: calc(50% - 2px);
}

.xnav-open .xnav-icon span:nth-child(3) {
  left: -100%;
  opacity: 0;
}

.xnav-open .xnav-icon span:nth-child(4) {
  left: 150%;
  opacity: 0;
}

.xnav-open .xnav-icon span:nth-child(5) {
  top: 14px;
  left: 2px;
}

.xnav-open .xnav-icon span:nth-child(6) {
  top: 14px;
  left: calc(50% - 2px);
}









xnav{
    position: fixed;
    inset: 0;
    display: grid;
    grid-template-rows: 1fr 1fr 1fr 1fr;
    grid-auto-flow: column;
    pointer-events: none;
    user-select: none;
    transition: 500ms ease-in-out;
    z-index:3;
}

xnav:has(:nth-child(1):hover) {
    grid-template-rows: 4fr 1fr 1fr 1fr;
}

xnav:has(:nth-child(2):hover) {
    grid-template-rows: 1fr 4fr 1fr 1fr;
}

xnav:has(:nth-child(3):hover) {
    grid-template-rows: 1fr 1fr 4fr 1fr;
}

xnav:has(:nth-child(4):hover) {
    grid-template-rows: 1fr 1fr 1fr 4fr;
}

.xnav-item {
  position: relative;
  width: 100vw;
  padding: 30px;
  font-size: 28px;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  color: #fff;
  background-size: cover;
  pointer-events: auto;
  display: flex;
  justify-content: center;
  align-items: center;
  transform: translateX(-100vw);
  transition: transform 0.65s;
}
.xnav-open .xnav-item {
  transform: translateX(0);
}




@media only screen and (min-width: 992px) {
    /* Split Column Slide Down Navigation */
    xnav {
        grid-template-rows: none;
        grid-template-columns: 1fr 1fr 1fr 1fr;
        grid-auto-flow: row;
    }

    xnav:has(:nth-child(1):hover) {
        grid-template-columns: 4fr 1fr 1fr 1fr;
    }

    xnav:has(:nth-child(2):hover) {
        grid-template-columns: 1fr 4fr 1fr 1fr;
    }

    xnav:has(:nth-child(3):hover) {
        grid-template-columns: 1fr 1fr 4fr 1fr;
    }

    xnav:has(:nth-child(4):hover) {
        grid-template-columns: 1fr 1fr 1fr 4fr;
    }

    .xnav-item {
        width:auto;
        height: 100vh;
        transform: translateY(-100vh);
    }

    .xnav-open .xnav-item {
        transform: translateY(0);    
    }
}



.xnav-item::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  opacity: 1;
  transition: opacity 0.3s ease-in-out;
}

.xnav-item:hover::after {
  opacity: 0.5;
}

.xnav-item:nth-child(1)::after {
  background-color: rgba(15, 66, 206, 0.5);
}

.xnav-item:nth-child(2)::after {
  background-color: rgba(230, 2, 127, 0.5);
}

.xnav-item:nth-child(3)::after {
  background-color: rgba(223, 1, 216, 0.5);
}

.xnav-item:nth-child(4)::after {
  background-color: rgba(182, 172, 30, 0.5);
}

.xnav-item:nth-child(1) {
  background-image: url("/afb/haus-fernblick-1.jpg");
}

.xnav-item:nth-child(2) {
  background-image: url("/afb/1-woon-3.jpg");
  transition-delay: 70ms;
}

.xnav-item:nth-child(3) {
  background-image: url("/afb/uitzicht-2.jpg");
  transition-delay: 30ms;
}

.xnav-item:nth-child(4) {
  background-image: url("/afb/front/skisprong.jpg");
  transition-delay: 100ms;
}
