/* for desktop-header */
.desktop-header {
  display: none;
  height: 140px;
  width: 100vw;
  position: fixed;
  top: 0;
  border-bottom: 40px solid #313538;
  z-index: 99;
  background-color: white;
}

.desktop-header > .logo {
  margin-left: 60px;
  margin-top: 26px;
}

.desktop-header > .logo > img:hover {
  animation-name: bouncing;
  animation-timing-function: ease;
  animation-duration: 2s;
  animation-iteration-count: infinite;
}

@keyframes bouncing {
  0% {
    transform: scale(1, 1) translateY(0);
  }
  10% {
    transform: scale(1.1, 0.9) translateY(0);
  }
  30% {
    transform: scale(0.9, 1.1) translateY(-40px);
  }
  50% {
    transform: scale(1.05, 0.95) translateY(0);
  }
  57% {
    transform: scale(1, 1) translateY(-7px);
  }
  64% {
    transform: scale(1, 1) translateY(0);
  }
  100% {
    transform: scale(1, 1) translateY(0);
  }
}

.desktop-header > .nav {
  display: flex;
  margin-left: 96px;
  margin-top: 44px;
}

.desktop-header .tag {
  letter-spacing: 30px;
  font-size: 20px;
  color: #3f3a3a;
  line-height: 28px;
}

.desktop-header .tag:hover {
  color: royalblue;
}

.tag-line {
  width: 34px;
  font-size: 20px;
  color: #3f3a3a;
  line-height: 28px;
  margin-left: 11px;
  margin-right: 5px;
}

.desktop-header > .search {
  width: 214px;
  height: 40px;
  padding: 8px 48px 8px 20px;
  border: solid 1px #979797;
  border-radius: 20px;
  outline: none;
  font-size: 20px;
  background-image: url(./../images/search.png);
  background-repeat: no-repeat;
  background-position: right center;
  margin-left: auto;
  margin-top: 30px;
}

.desktop-header .cart {
  margin-top: 28px;
  margin-left: 42px;
  position: relative;
}

.cart img,
.member img {
  height: 44px;
}

.desktop-header .count {
  position: absolute;
  text-align: center;
  background-color: #8b572a;
  font-weight: bold;
  border-radius: 50%;
  color: #ffffff;
  opacity: 0.8;
  width: 24px;
  height: 24px;
  line-height: 24px;
  bottom: 0;
  right: 0;
}

.desktop-header .member {
  margin-top: 28px;
  margin-left: 42px;
  margin-right: 54px;
  cursor: pointer;
}

/* for mobile-header */
.mobile-header {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 52px;
  width: 100%;
  position: fixed;
  top: 0;
  z-index: 99;
  background-color: white;
}

.mobile-header > a > img {
  height: 20px;
}
.mobile-header > a > img:hover {
  animation: pulse 1s infinite ease-in-out alternate;
}

@keyframes pulse {
  from {
    transform: scale(0.8);
  }
  to {
    transform: scale(1.2);
  }
}

.mobile-header > .search {
  width: 0;
  height: 40px;
  padding: 20px;
  border: none;
  border-radius: 20px;
  outline: none;
  font-size: 16px;
  background-image: url(./../images/search.png);
  background-repeat: no-repeat;
  background-position: right center;
  background-size: 32px;
  position: absolute;
  right: 10px;
  cursor: pointer;
}

.mobile-header > .search:focus {
  width: calc(100% - 20px);
  padding: 8px 48px 8px 20px;
  border: solid 1px #979797;
  left: 10px;
  cursor: text;
}

/* for mobile-nav */
.mobile-nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  width: 100%;
  top: 51px;
  position: fixed;
  height: 40px;
  background-color: #313538;
  color: #828282;
  z-index: 99;
}
.mobile-nav .tag:hover {
  color: cyan;
}

.mobile-nav-text {
  flex-grow: 1;
  text-align: center;
  color: #828282;
}

.mobile-nav-text + .mobile-nav-text {
  border-left: 2px solid #828282;
}

/* for main */
main {
  margin-top: 91px;
  min-height: calc(100vh - 300px);
}

/* media query for header */
@media (min-width: 1280px) {
  .desktop-header {
    display: flex;
    align-items: flex-start;
  }

  .mobile-header {
    display: none;
  }

  .mobile-nav {
    display: none;
  }

  main {
    min-height: calc(100vh - 207px);
  }
}
