* {
  padding: 0;
  margin: 0;
}

html {
  height: 100%;
  box-sizing: border-box;
}

body {
  min-height: 100%;
  min-width: 100vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.wrapper{
  display: grid;
  z-index: 1;
  margin-bottom: 20px;
  margin-left: 50px;
  margin-right: 50px;
  margin-top: 50px;
}

.mainimage {
  margin-bottom: 20px;
}

header {
  display: flex;
  justify-content: center;
  font-weight:bold;
}


#headerimg {
  width: 100%; /*or whatever you choose*/
  margin: 0;
  padding: 50px 50px;
}
#headerimg img {
  display: block;
  width: 100%;
  max-width: 274.34px; /*actual image width*/
  height: auto; /* maintain aspect ratio*/
  margin: auto;
}
#headerimg a {
  display: block;
  width: 100%;
  max-width: 274.34px; /*actual image width*/
  height: auto; /* maintain aspect ratio*/
  margin: auto;
}

footer {
  display: grid;
  margin-top: auto;  
  align-items: center;
  margin-right: 50px;
  margin-left: 50px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, minmax(min-content, 1fr));
  grid-auto-rows: minmax(1px, auto);
}

#info {
  justify-content: flex-end;
  align-items: center;
  margin-bottom: 10px;
  margin-top: 10px;
  font-family: urw-din,sans-serif;
  font-weight: 300;
  font-style: normal;
  font-size: 10px;
}

#terms {
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: urw-din,sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 10px;
  margin-bottom: 20px;
  margin-top: 5px;
}

#terms a {
  text-decoration: none;
  color: black;
}

#terms a:hover {
  opacity: 70%;
}

#terms a:visited {
  text-decoration: none;
  color: black;
}

#footerp {
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: urw-din,sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 15px;
}

#gap {
  min-width: 1px;
  min-height: 1px;
}

/* Style all font awesome icons */
#social {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  justify-content: flex-end;
  justify-self: flex-end;
  font-size: 20px;
}

.fa {
  padding: 10px;
  font-size: 20px;
  text-align: center;
  text-decoration: none;
}

/* Add a hover effect if you want */
.fa:hover {
  opacity: 0.5;
}

/* Twitter */
.fa-twitter {
  background: white;
  color: black;
}

.fa-instagram {
  color: black;
}

.fa-facebook {
  color: black;
}

.fa-envelope {
  color: black;
}

.fa-phone {
  color: black;
}

.main-nav {
  height: minmax(30px, auto);
  padding: 0 50px;
}

.main-nav ul{
  display: grid;
  align-items: center;
  font-family: urw-din,sans-serif;
  font-weight: 700;
  font-style: normal;
  grid-gap: 20px;
  list-style: none;
  grid-template-columns: repeat(5, 1fr);
  grid-auto-rows: 30px;
  color: black;
}

.main-nav a{
  display: block;
  color: black;
  text-decoration: none;
  text-align: center;
  font-size: 17px;
  font-weight: 700;
}

.main-nav a:visited{
  color: black;
}

.main-nav a:hover{
  opacity: 0.5;
}

.line {
  height: 1.5px;
  margin-top: 42px;
  margin-left: 9.4%;
  margin-right: 10.2%;
  background-color: black;
}
#title-text {
  text-align: center;
  font-size: 18px;
}
.walloftext {
  display: flex;
  align-items: center;
  font-family: 'Noto Serif KR', serif;    
  font-size: 7px;
}

.error {
  text-align: center;
}

@media(max-width: 850px) {
  .footer-content {
      grid-template-columns: 1fr;
    }
  
    #social {
      justify-self: center;
      justify-content: center;
      order: 2;
    }

    #terms {
      justify-content: center;
      justify-self: center;
      order: 3;
    }

    .main-nav {
      padding-right: 0;
      padding-left: 0;
    }
}

@media(max-width: 650px) {
  .main-nav ul {
    grid-template-columns: 1fr;
    grid-gap: 0;
    padding-left: 0;
  }
}

@media(max-width: 980px) {
  #terms {
    display: grid;
    grid-template-rows: 20px 1fr;
  }

  #privacy {
    display: flex;
    justify-content: center;
  }

  #terms a {
    order: 2;
    justify-content: center;
  }
}

@media(min-height: 1250px) {
  .wrapper {
    margin-top: 75px;
  }
}

@media(min-width: 1500px) {
  .wrapper {
    margin-left: 9.4%;
    margin-right: 10.2%;
  }
}

@media(max-width: 241px) {
  #social {
    width: 100%;
    grid-template-columns: 1fr 1fr 1fr
  }
}