html, body {
  padding: 0;
  margin: 0;
  width: 100%;
  height: 100%;
  background-color: #eee;
}
main {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: auto;
}

textarea, input {
  font-family: "Source Sans Pro", "Helvetica Neue", sans-serif;
  font-size: 0.8em;
}

button {
  font-family: "Source Sans Pro", "Helvetica Neue", sans-serif;
  border: none;
  background-color: #1E90FF;
  color: white;
  cursor: pointer;
}

#main-page a, #main-page a:visited {
  text-decoration: none;
  color: #1E90FF;
  font-weight: 400;
}
#main-page a:hover {
  text-decoration: underline;
}
#container {
  background-color: white;
  font-family: "Source Sans Pro", "Helvetica Neue", sans-serif;
  font-weight: 300;
  box-shadow: 0 10px 24px 0px rgba(0, 0, 0, 0.1);

  width: 650px;
  margin: 0 auto;
  padding: 40px 0px 40px 0px;
  border-radius: 8px;
}
#header {
  display: flex;
  justify-content: center;
  flex-flow: column wrap;
  font-size: 1.5em;
  align-items: center;
}
#content {
  text-align: center;
  font-size: 1.5em;
  margin: 0 auto;
  max-width: 500px;
  color: #555;
  padding-top: 10px;
}
#avatar {
  clip-path: circle(50px at center);
  -webkit-clip-path: circle(50px at center);
  margin-top: 9px;
  margin-left: 1px;
  width: 100px;
  height: 100px;
}
#name {
  font-size: 2.0em;
  font-weight: 400;
  padding-top: 10px;
}
#location {
  font-size: 0.85em;
  color: #aaa;
  font-weight: 400;
}
#footer {
  text-align: center;
  font-size: 1.2em;
  cursor: default;
  padding-top: 10px;
  padding-left: 15px;
  padding-right: 15px;
}
#footer a, #footer a:visited {
  text-decoration: none;
  color: #ccc;
  margin-left: 15px;
  margin-right: 15px;
  font-size: 2em;
  -webkit-transition: color 0.25s;
  -moz-transition: color 0.25s;
  -o-transition: color 0.25s;
  transition: color 0.25s;
}
#footer a:hover {
  color: #1E90FF;
  -webkit-transition: color 0.25s;
  -moz-transition: color 0.25s;
  -o-transition: color 0.25s;
  transition: color 0.25s;
}
#contact-page {
  display: none;
  font-size: 1.5em;
  padding-left: 35px;
  padding-right: 35px;
  color: #555;
}
#contact-page-header {
  display: flex;
  justify-content: space-between;
}
#contact-page-title {
  font-size: 1.5em;
  font-weight: 400;
  flex-direction: column;
  line-height: 0.9em;
}
#contact-page-subtitle-span {
  font-size: 0.6em;
  font-weight: 400;
  color: #aaa;
  line-height: 1.2em;
  margin-top: 4px;
}
button#contact-page-close {
  color: #999;
  flex-basis: content;
  justify-content: flex-end;
  text-decoration: none;
  font-size: 0.8em;
  background-color: transparent;
  font-weight: 300;
  padding: 0;
}
button#contact-page-close:hover {
  color: #666;
}
#contact-page-close > i {
  margin-right: 3px;
}
#contact-page form {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  padding-top: 30px;
  justify-content: flex-end;
}
#contact-page input, #contact-page textarea {
  font-size: 0.8em;
  margin-left: 0px;
  margin-right: 0px;
  margin-bottom: 15px;
  padding: 4px 8px 4px 8px;
  border: 1px solid #ddd;
  resize: none;
}
#contact-page textarea {
  box-sizing: border-box;
  height: 200px;
}
#contact-page input::placeholder, #contact-page textarea::placeholder {
  color: #bbb;
}
#contact-page .partial-left {
  flex: 1 1 auto;
  margin-right: 15px;
}
#contact-page .partial-right {
  flex: 1 1 auto;
}
#contact-page .full {
  flex-basis: 100%;
}
#contact-page-submit {
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.8em;
  padding: 6px 15px 6px 15px;
  display: flex;
  align-items: center;
  height: 36px;
  box-sizing: border-box;
}
#contact-page-submit:hover {
  background-color: #1976d1;
}
#contact-page-submit:disabled {
  background-color: #aaa;
}
#contact-page-confirmation {
  justify-content: flex-start;
  flex: 1 1 auto;
  align-self: center;
  font-size: 0.9em;
  font-weight: 400;
  color: #4BB543;
  display: none;
}
input:disabled, textarea:disabled {
  color: #bbb;
}
#contact-page-footer {
  margin-top: 15px;
}

/* Mobile */
@media all and (max-width: 700px), (max-height: 660px) {
  main {
    font-size: 0.8em;
    justify-content: flex-start;
    background-color: white;
  }
  #container {
    width: 100%;
    border-radius: 0px;
    box-shadow: none;
    padding-top: 30px;
  }
  #content {
    font-size: 1.6em;
    margin: 0 auto;
    max-width: 500px;
    padding-left: 35px;
    padding-right: 35px;
  }
  #location {
    font-size: 0.9em;
    color: #aaa;
    font-weight: 400;
  }
  #avatar {
    clip-path: circle(40px at center);
    -webkit-clip-path: circle(40px at center);
    margin-top: 10px;
    width: 80px;
    height: 80px;
  }
  #footer {
    font-size: 1.3em;
  }
  #footer a {
    margin-left: 10px;
    margin-right: 10px;
  }
  #contact-page .partial-left {
    margin-right: 0px;
    flex-basis: 100%;
  }
}

/* Dark Mode */
@media(prefers-color-scheme: dark) {
  body {
    background-color: #222;
  }
  #container {
    background-color: #444;
    color: white;
    box-shadow: 0 10px 24px 0px rgba(0, 0, 0, 0.4);
  }
  #content {
    color: white;
  }
  #main-page a, #main-page a:visited {
    color: #1eb6ff;
  }
  #footer a, #footer a:visited {
    color: #aaa;
  }
  #footer a:hover {
    color: white;
  }
  #contact-page {
    color: white;
  }
  #contact-page-submit {
    background-color: #1eb6ff;
  }
  #contact-page input, #contact-page textarea {
    background-color: #333;
    border-color: #555;
    color: white;
  }
  #contact-page-close {
    color: #ccc;
  }
  button#contact-page-close:hover {
    color: white;
  }
}

@media(prefers-color-scheme: dark) and (max-width: 700px), (max-height: 660px) {
  main {
    background-color: #444;
  }
  #container {
    box-shadow: none;
  }
}

input, textarea {
  -webkit-appearance: none;
}
