/* ---- Mobile Header ---- */
.g-header-m { display: none; }

/* ---- Header ---- */
.g-header {
  background: #212224;
  display: flex;
  justify-content : space-between;
  align-items: center;
  width: 100%;
  height: 80px;
  padding: 0 20px;
  position: fixed;
  left: 0; top: 0;
  z-index: 10;
}
.g-header__col {
  display: flex;
  align-items: center;
  gap: 40px;
}
.g-header__logo {
  width: 100px; height: 15.95px;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/logo.png') no-repeat center center / 100% auto;
}
.g-header__menu {
  display: flex;
  gap: 40px;
  text-transform: uppercase;
}
.g-header__menu-item {
  cursor: pointer;
  transition: color 0.3s;
  color: white;
  &:hover{
      color:var(--accent-color);
  }
}

.g-header__user, .g-header-m__menu-item.user {
  display: flex;
  align-items: center;
    &:hover{
      #user-name {
        color:var(--accent-color);
    }
  }
  .dropdown-toggle {
    background: none;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 0;
    &:after {
      display: none;
    }
  }
  .dropdown-menu {
    background: #212224 !important;
    border: 1px solid #59595b;
    min-width: 150px !important;
    &:before, &:after {
        display: none;
    }
    #user-menu {
        a { color: white; 
            &:hover {
                color: black;
            }
        }
    }
  }
  .user-avatar {
    width: 29px; height: 29px;
    border-radius: 50%;
    transition: all 0.3s;
  }
  #user-name {
    color: white;
    line-height: 1em;
    font-size: 16px;
    transition: color 0.3s;
  }
  .login{
    color: white;
    border-color: white;
    text-transform: uppercase;
    font-size: 14px;
    padding: 0 12px;
    transition: all 0.3s;
    &:hover {
      border-color: var(--accent-color);
      background: var(--accent-color);
    }
  }
}
.g-header__language-selector {
  display: flex;
  gap: 10px;
  align-items: center;
  &:hover{
    .dropdown-toggle {
     color:var(--accent-color);
    }
  }
  .globe {
    background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/globe.png') no-repeat center center / 100% auto;
    width: 30px; height: 30px;
  }
  .dropdown-toggle {
    transition: color 0.3s;
    line-height: 1em;
    font-size: 16px;
  }
  .dropdown-menu {
    top: 35px;
    background: #212224;
    border: 1px solid #59595b;
    [role=menuitem]  {
        color: white;
        &:hover {
          background: white;
          color: black;
        }
    }
  }
}

/* ---- Header Notice ---- */
.g-header-notice {
  &.active {
      display: flex;
  }
  &.animate-show {
      transform: translateY(0);
  }
  position: fixed;
  background: var(--header-notice-bg);
  left: 0;
  top: 80px;
  width: 100%;
  height: 48px;
  display: none;
  justify-content: center;
  align-items: center;
  gap: 10px;
  z-index: 5;
  transform: translateY(-120%);
  transition: transform 0.3s;
  a {
    width: 1000px;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    &:hover {
        color: var(--link-color-hover);
    }
  }
}
.g-header-notice__icon {
  width: 26px;
  height: 26px; display: inline-block; vertical-align: middle;
  margin-right: 10px; 
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/important_exclamation.png') no-repeat center center / 100% auto;
  flex: 0 0 auto;
}
.g-header-notice__text {
  display: inline-block;
  font-size: 18px; line-height: 1.1em; margin-top: 2px;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
.g-header-notice__close-icon {
  width: 26px;
  height: 26px;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon.png') no-repeat center center / 100% auto;
  transition: background 0.3s;
  cursor: pointer;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  &:hover{
      background-image: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon-hover.png');
  }
}

/* ---- Game List ---- */
.g-header-games {
  position: fixed;
  width: 100%;
  overflow: hidden;
  left: 0;
  top: 0;
  z-index: 9;
  transition: height 0.3s;
  display: none;
  height: 100%;
  &.active{
    display: block;
  }
  &.animate-show {
    .g-header-games__outter  { 
      opacity: 1;
    }
    .g-header-games__content  {
        transform: translateY(0);
    }
    .c-game-thumbnail--dropdown  {
        opacity: 1;
        transform: scale(1);
        }
    .g-header-games__close-icon {
        opacity: 1;
    }
  }
}
.g-header-games__outter {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%; height: 100%;
  transition: opacity 0.3s;
  background: rgba(0, 0, 0, 0.8);
  z-index: 0;
  opacity: 0;
}
.g-header-games__content {
  background: #151517;
  width: 100%;
  padding: 100px 10px;
  padding-top: 100px; padding-bottom: 25px;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
  transition: transform 0.3s cubic-bezier(.42,0,.58,1);
  display: flex;
  justify-content: center;
  transform: translateY(-100%);
    
}
.g-header-games__close-icon {
  position: absolute;
  left: 50%;
  top: 100px;
  opacity: 0;
  cursor: pointer;
  transition: opacity 0.3s 0.7s;
  transform: translateX(calc(-50% + 600px));
  width: 31px; height: 31px;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon.png') center center/ 100% auto;
  transition: background 0.3s;
  &:hover, &:after {
    content: '';
    background-image: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon-hover.png');
  }
}

.g-header-games__games {
  display: flex;
  gap: 20px 10px;
  max-width: 1050px;
  align-content: flex-start;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---- Search Drawer---- */
/* ---- Search Desktop ---- */
.g-search {
  position: fixed;
  width: 100%;
  overflow: hidden;
  left: 0;
  top: 0;
  z-index: 9;
  transition: height 0.3s;
  display: none;
  height: 100%;
  &.active{
    display: block;
  }
  &.animate-show {
    .g-search__outter { 
      opacity: 1;
    }
    .g-search__content-wrapper  {
        transform: translateY(0);
        opacity: 1
    }
    .g-search__close-icon {
        opacity: 1;
    }
  }
}
.g-search__outter {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%; height: 100%;
  transition: opacity 0.3s;
  background: rgba(0, 0, 0, 0.8);
  z-index: 0;
  opacity: 0;
}
.g-search__content-wrapper {
  background: #151517;
  width: 100%;
  padding: 140px 10px 80px;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
  opacity: 0;
  transition: transform 0.3s cubic-bezier(.42,0,.58,1), opacity 0.3s;
  transform: translateY(-100%); 
}
.g-search__content {
  width: 900px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}
.g-search__close-icon {
  position: absolute;
  left: 50%;
  top: 100px;
  opacity: 0;
  cursor: pointer;
  transition: opacity 0.3s 0.7s;
  transform: translateX(calc(-50% + 600px));
  width: 31px; height: 31px;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon.png') center center/ 100% auto;
  transition: background 0.3s;
  &:hover, &:after {
    content: '';
    background-image: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon-hover.png');
  }
}

.g-search__input {
  width: 100%;
  max-width: 800px;
  input[type="search"] {
    text-transform: capitalize;
    box-sizing: border-box;
    padding-bottom: 10px;
    border: none;
    border-bottom: 1px solid white;
    background: none;
    font-size: 32px;
    cursor: pointer;
    width: 100%;
    color: white;
    background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/search-icon-white.png') no-repeat right 12px center;
    &::placeholder {
      transition: color 0.3s 0.1s;
      color: rgba(255,255,255,0.55);
    }
  }
  input[type="submit"] {
    display: none;
  }
}

.g-search__empty-space {
  transition: height 0.05s;
}

.g-search__text-reset-icon {
  position: absolute;
  right: 20px; top: 59px;
  width: 18px; height: 18px;
  opacity: 0;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/close-icon-no-circle.png') no-repeat center center / 100% auto;
  display: none;
  transition: opacity 0.3s, transform 0.3s;
  transform: scale(1.4);
  &.show{
    transform: scale(1);
    opacity: 0.7;
  }
}

/* Build In Search Result Popup. */
zd-autocomplete {
  background-color: transparent;
  box-shadow: none;
  overflow: hidden;
   padding-bottom: 20px;
}

@media screen and (min-width: 375px) {
  zd-autocomplete {
      min-width: 0;
  }
}

zd-autocomplete-header {
  border-bottom: none;
  color: white;
  font-size: 26px;
  font-weight: bold;
  display: block;
  text-align: left;
  display: flex;
  padding-left: 3px; padding-bottom: 0px;
  margin-bottom: 0px;
}

zd-autocomplete-option {
  color: rgba(255,255,255,0.6);
  transition: color 0.3s;
  display: block;
  font-size: 18px;
  padding-left: 3px;
  background: none !important;
  &:hover{
    color: rgba(255,255,255,1);
    background: none;
  }
  em { color: rgba(255,255,255,1);  font-weight: bold; }
}

zd-autocomplete-option[aria-selected=true] {
  background-color: none;
}


/* ---- Hero for every page ---- */
.g-hero {
  max-width: 1000px;
  position: relative;
  margin: 120px auto 0px; height: 250px;
  padding: 0 20px;
  background: var(--hero-logo) no-repeat center 59px;
  &:after {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
    content: '';
    width: calc(100% - 40px);
    height: 1px;
    background: #8a8a8b;
  }
}
.g-hero__search {
  position: absolute;
  right: 20px;
  top: 71px;
  width: 44px; height: 44px;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/ui/search-icon.png') #ffffff no-repeat right 12px center;
}
 


@media (max-width: 1280px) {
  .g-header-games__close-icon  {
    transform: translateX(calc(-50% + 510px));
  }
}

@media (max-width: 1090px) {
  .g-header-games__content {
    padding: 125px 10px;
  }
  .g-header-games__close-icon  {
    top: 84px;
    left: auto; right: 20px;
    transform: translateX(0);
  }
}

@media (max-width: 1100px) { 
  .g-header__col, .g-header__menu {
    gap: 20px;
  }
}

@media (max-width: 1050px) {

  /* ---- Header  ---- */
  .g-header {
    display: none;
  }

  .g-header__language-selector {
    width: 100%;

    .dropdown {
      position: relative;
      flex: 1;
    }

    .globe {
      width: 25px;
      height: 25px;
    }

    .dropdown-toggle {
      margin-bottom: 3px;

      &:after {
        position: absolute;
        right: 0;
        top: 4px;
      }

      &:hover {
        color: white;
      }
    }

    .dropdown-menu {
      left: calc(-38px);
      width: calc(38px + 100%);
    }
  }

  /* ---- Mobile Header ---- */
  .g-header-m {
    background: #212224;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 75px;
    display: block;
    z-index: 8;

    &.active {
      height: 100%;

      .g-header-m__content {
        display: block;
      }
    }

    &.animate-show {
      .g-header-m__content {
        opacity: 1;
        height: 100%;
      }
    }

    &.submit-ticket-active,
    &.game-list-active {
      .g-header-m__content-logo {
        opacity: 0;
      }

      .g-header-m__back-icon {
        opacity: 1;
      }
    }

    &.game-list-active {
      .g-header-m__ui-text--game-list {
        opacity: 1;
        transform: translate(-50%, -50%);
      }
    }

    &.submit-ticket-active {
      .g-header-m__ui-text--submit {
        opacity: 1;
        transform: translate(-50%, -50%);
      }
    }
  }

  .g-header-m__content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: #212224;
    overflow: hidden;
    display: none;
    opacity: 0;
    transition: height 0.3s, opacity 0.3s;
  }

  .g-header-m__content-header {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 75px;
    border-bottom: 3px solid rgba(0, 0, 0, 0.15);
    margin-bottom: 20px;
    position: relative;
  }

  .g-header-m__back-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-47%);
    width: 15px;
    height: 27px;
    opacity: 0;
    background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/mobile/back-arrow.png') center center / 100% auto;
  }

  .g-header-m__close-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    transition: color 0.3s;

    &:hover {
      color: var(--accent-color);
    }
  }

  .g-header-m__ui-text {
    position: absolute;
    left: 50%;
    top: 51%;
    transform: translate(-50%, -200%);
    text-transform: uppercase;
    font-size: 16px;
    width: 150px;
    height: 50px;
    line-height: 1.05em;
    text-align: center;;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.3s;
    opacity: 0;
  }

  .g-header-m__content-logo {
    width: 90px;
  	height: 14.95px;
  	margin-top: 3px;
  	background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/logo.png') no-repeat center center / 100% auto;
    transition: opacity 0.3s;
  }

  .g-header-m__menu {
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
  }

  .g-header-m__menu-item {
    text-transform: uppercase;
    position: relative;
    color: white;

    &:hover {
      color: var(--accent-color);
    }

    &.user {
      .dropdown {
        width: 100%;
      }

      .dropdown-toggle {
        padding: 0;
        justify-content: left !important;

        &:after {}
      }

      .dropdown-menu {
        left: 0;
        width: 100%;
      }
    }

    &.more-menu {
      &:before {
        position: absolute;
        display: inline-block;
        right: 0px;
        top: 7px;
        content: '';
        width: 5px;
        height: 9px;
        background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/mobile/arrow-right.png') center center / 100% auto;
      }
    }
  }

  .g-header-m__header {
    display: flex;
    height: 75px;
    justify-content: space-between;
    padding: 0 20px;
    align-items: center;
  }

  .g-header-m__logo {
    width: 90px;
  	height: 14.95px;
  	background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/logo.png') no-repeat center center / 100% auto;
    margin-top: 2px;
  }

  .g-header-m__menu-icon {
    width: 23px;
    height: 20px;
    cursor: pointer;
    background: url('https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/mobile/menu-icon.png') no-repeat center center / 100% auto;
  }

  /* ---- Header Notice ---- */
  .g-header-notice {
    a {
      width: 85%;
    }
  }

  .g-header-notice__text {
    font-size: 16px;
  }

  .g-header-notice__close-icon {
    width: 20px;
    height: 20px;
    right: 10px;
  }

  /* ---- Game List ---- */
  .g-header-games {
    top: 75px;
    height: calc(100% - 75px);
  }

  .g-header-games__content {
    padding-top: 30px;
    height: 100%;
    overflow-Y: scroll;
  }

  .g-header-games__close-icon {
    display: none;
  }

  .g-header-games__games {
    width: 100%;
  }



  /* ---- Search Drawer---- */
  .g-search {
    &.animate-show {
      .g-search__content-wrapper  {
  				opacity: 1;
          transform: scale(1) translateY(0);
      }
    }
  }
  .g-search__content-wrapper {
  	overflow: hidden;
  	height: 100%;
  	opacity: 0;
  	transform: scale(1.15) translateY(0);
  	transition: opacity 0.3s, transform 0.3s;
  	display: flex;
  	flex: 1;
    justify-content: space-between;
    gap: 20px;
  	padding: 50px 20px;
  	align-items: flex-start;
  	background: rgb(27,27,27,0.7)
  }
  .g-search__content { 
  	width: 100%;
  }
  .g-search__input {
  	max-width: none;
    input[type="search"] {
  		background: none;
  		padding-right: 30px;
  		font-size: 20px;
  	}
  }
  .g-search__close-icon {
  	position: static;
  	transform: translate(0,0);
  	width: 15px; height: 23px;
  	margin-top: 7px;
    background: url(https://nxcache.nexon.net/support/2024/global-2025/v-1.1.0/imgs/global/header/mobile/back-arrow.png) no-repeat center center / 100% auto;
  }
  .g-search__empty-space {
  	display: none;
  }
  .g-search__input {
  	position: static;
  }
  .g-search__text-reset-icon { 
  	display: block;
  }
  zd-autocomplete {
    max-width: 100%; overflow: hidden;
	}


  /* ---- Hero for every page ---- */
  .g-hero {
    height: 190px;
    background: var(--hero-logo) no-repeat center 15px / 300px auto;
  }

  .g-hero__search{
  	top: auto !important;
    bottom: 23px;
    left: 50%;
    transform: translateX(-50%);
  }

  /* ---- Header Notice  ---- */
  .g-header-notice {
    height: 44px;
    top: 74px;
  }

}
@media (max-width: 400px) {
  zd-autocomplete-option {
    font-size: 14px;
  }
  .g-search__content-wrapper { 
  	gap: 12px;
  }
  .g-search__close-icon {
  	margin-top: 4px; 
  }
  .g-search__text-reset-icon { 
  	width: 16px; height: 16px;
  	top: 55px;
  }
	.g-search__input {
    input[type="search"] {
  		padding-right: 20px;
  		padding-bottom: 7px;
  		font-size: 16px;
  	}
  }
}