@import '@/styles/variables';
@import '@/styles/font-styles';

.is-home {
  .header-menu {
    display: block;

    @include tablet-only-home {
      display: none!important;
    }

    @include mobile {
      display: none!important;
    }
  }

  .header-mobile-menu {
    display: none;

    @include tablet-only-home {
      display: block!important;
    }

    @include mobile {
      display: block!important;
    }
  }

  .footer {
    display: flex;

    @include tablet-only-home {
      display: block!important;
    }

    @include mobile {
      display: none!important;
    }
  }
}

.container {
  position: relative;
  height: 100vh;
  overflow: hidden;

  section {
    height: 100vh;
    width: 100%;

    @include tablet-only-home {
      height: auto;
    }

    @include mobile {
      height: auto;
    }
  }

  .work-section {
    .work-section-item.item-two {

      figcaption {
        opacity: 0;
      }

      .image-mask {
        transform: translateY(80%);
        transition: transform 1s cubic-bezier(.19,1,.22,1);
      }
    }

    & > .initial-state {

      .work-section-item.item-one {
        opacity: 0;
        transition: all 0.25s linear;
        transform: translateY(-50px);
      }

      .work-section-item.item-two {
        opacity: 1;
        
        figcaption {
          opacity: 0;
          transition: opacity 0.25s linear;
        }
        
        .image-mask {
          transform: translateY(55%);
        }

        .work-section-gallery {
          opacity: 1;
        }

        .image-mask-inner {
          opacity: 0;
        }
      }
    }

    & > .initial-state.initial-state-change {
      z-index: 2;

      .work-section-item.item-one {
        opacity: 1;
        transform: translateY(0);
      }

      .work-section-item.item-two {
        opacity: 1;
        
        figcaption {
          opacity: 1;
        }
        
        .image-mask {
          animation: none;
          transform: translateY(0)!important;
        }

        .work-section-gallery {
          opacity: 0;
        }

        .image-mask-inner {
          opacity: 1;
        }
      }
    }
  }

  @include tablet-only-home {
    height: auto;
    min-height: 100vh;
    background-color: $gray-001;

    section {
      height: auto;
    }
  }

  @include mobile {
    background-color: $gray-001;
    min-height: 100vh;
    height: auto;

    section {
      height: auto;
    }
  }
}

.main-title {
  position: absolute;
  height: 100vh;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
  transition: opacity 0.25s linear;
  z-index: 2;

  .main-title-desktop {
    display: block;

    @include small-desktop {
      display: none;
    }

    @include tablet-only-home {
      display: none;
    }

    @include mobile {
      display: none;
    }
  }

  .main-title-tablet {
    display: none;

    .main-title-item {
      margin-bottom: 10px;

      img {
        width: 84%;
      }

      &:first-child {
        img {
          width: 80%;
        }
      }

      &:last-child {
        img {
          width: 57%;
        }
      }
    }

    @include small-desktop {
      display: block;
      width: 80%;

      .main-title-item {
        img {
          width: 100%;
        }
  
        &:first-child {
          img {
            width: 95%;
          }
        }
  
        &:last-child {
          img {
            width: 69%;
          }
        } 
      }
    }

    @include tablet-only-home {
      display: block;
    }

    @include mobile {
      display: none;
    }
  }

  .main-title-mobile {
    display: none;

    .main-title-item {
      &:nth-child(2) {
        margin-top: -18px; 
      }
    }

    @include tablet-only-home {
      display: none;
    }

    @include mobile {
      display: block;
    }
  }

  .main-title-item {
    margin-bottom: 5px;
    overflow: hidden;

    &:last-child {
      margin-bottom: 0;
    }
  }

  span {
    display: block;
  }

  @include tablet-only-home {
    position: static;
    padding: 100px 12px 30px;
    display: block;
    background-color: $white;
    opacity: 1;

    h1 {
      width: 100%;
      font-size: 94px;
      line-height: 78px;
      letter-spacing: -10px;
      overflow-wrap: break-word;
    }
  }

  @include mobile {
    position: static;
    padding: 100px 12px 15px;
    display: block;
    background-color: $white;
    opacity: 1;

    h1 {
      width: 100%;
      font-size: 52px;
      line-height: 52px;
      letter-spacing: -3px;
      overflow-wrap: break-word;
    }
  }
}

.directional-arrow {
  position: fixed;
  left: 50%;
  bottom: 112px;
  color: $black;
  display: flex;
  align-items: center;
  transform: translateX(-50%) rotate(-90deg);
  transform-origin: center center;
  cursor: pointer;
  text-decoration: none;
  opacity: 0;
  transition: 0.2s opacity linear;
  z-index: 3;

  .text {
    @extend .navigation;
  }

  .icon {
    width: 12px;
    height: 19px;
    margin-right: 12px;
    transform: scale(-1);

    svg {
      width: 100%;
    }
  }

  &.show {
    opacity: 1;
  }

  @include tablet-only-home {
    display: none;
  }

  @include mobile {
    display: none;
  }
}

.slider-arrow {
  display: none;
  width: 100%;
  background-color: $gray-001;
  opacity: 0;
  transition: opacity 0.25s linear;

  .slider-arrow-icon {
    width: 12px;
    height: 19px;
    margin-left: 10px;

    svg {
      width: 100%;
    }
  }

  @include mobile {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 16px 26px 26px;

    &.active {
      opacity: 1;
    }
  }
}