:root {
  --font-size: calc(16px + (22 - 16) * (100vw - 375px) / (1440 - 375));
  --font-body: "Replace Sans S", -apple-system, BlinkMacSystemFont, sans-serif;

  --color-dim: #666666;
  --color-gray: #F2F2F2;
  --color-purple: #926EE8;

  --unit-xs: 0.8rem;
  --unit-s: 1rem;
  --unit-m: 2rem;
  --unit-l: 4rem;
  --unit-xl: 8rem;
}

/*
========================
BASE
========================
*/

body {
  background: white;
  color: black;
}

/*
========================
FADE IN
========================
*/

@keyframes fadein {
    from {
        opacity:0;
        transform: translateY(0.5em);
    }
    to {
        opacity:1;
        transform: translateY(0);
    }
}
@-moz-keyframes fadein {
    /* Firefox */
    from {
        opacity:0;
        transform: translateY(0.5em);
    }
    to {
        opacity:1;
        transform: translateY(0);
    }
}
@-webkit-keyframes fadein {
    /* Safari and Chrome */
    from {
        opacity:0;
        transform: translateY(0.5em);
    }
    to {
        opacity:1;
        transform: translateY(0);
    }
}
@-o-keyframes fadein {
    /* Opera */
    from {
        opacity:0;
        transform: translateY(0.5em);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/*
========================
TYPOGRAPHY
========================
*/

html {
  font-size: var(--font-size);
}

body {
  font-family: var(--font-body);
  line-height: 1.325;
}

h1 {
  font-family: "Replace Sans M", -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 400;
  font-size: 1.5em;
  line-height: 1;

  text-box: trim-both cap alphabetic;
}

a {
  color: inherit;
  transition: all 0.2s ease-in-out;

  text-decoration-color: rgba(0,0,0,0.1);
  text-underline-offset: 0.25em;
}

a:hover {
  color: var(--color-purple);
  text-decoration-color: var(--color-purple);
}

/*
========================
LAYOUT
========================
*/

.content {
  display: grid;
  grid-template-columns: 1fr;
  margin: var(--unit-s);
  margin-top: calc(50vh - 1.5lh);
}

.site-title,
main {
  grid-row: 1;
  grid-column-start: 1;
  grid-column-end: -1;
}

.site-title {
  display: flex;
  justify-content: space-between;
  width: 100%;

  grid-column-start: 1;
  grid-column-end: -1;
}

.site-title h1 {
  display: flex;
  justify-content: space-between;
  width: 100%;
}

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.description {
  font-size: 1.5em;
  opacity: 0.4;
}

@media only screen and (max-width: 960px) {
  .site-title,
  .site-title h1 {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    grid-row: none;

    position: fixed;
    height: calc(100vh - 20vh);
    top: 10vh;
    z-index: -1;
  }

  .content {
    margin-top: 0;

    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
  }
}


/*
========================
FORM
========================
*/

form {
  grid-column-start: 2;
  grid-column-end: 3;

  background: var(--color-gray);
  border-radius: 0.5em;
  display: inline-flex;
  font-size: 0.825em;
  margin: 0.325em;
  box-shadow: 0px 15px 17px 0px rgba(0, 0, 0, 0);
  grid-gap: 0;
  overflow: hidden;

  transition: 0.5s all cubic-bezier(0.5,0,0,1);
}

form input {
  -webkit-appearance:none;
  border: 0;
  background: transparent;
  padding: 0;
}

form input:focus {
  outline: none;
}

form > input,
form > label {
  line-height: 1;
  padding: 1em;
}

form input[type="email"] {
  transition: 0.5s all cubic-bezier(0.5,0,0,1);
  width: 14em;
}

form:hover input[type="email"],
form:focus-within input[type="input"] {
  width: 15em;
}

form input[type="email"]:focus,
form label:focus-within {
  border-radius: 0.5em;
  outline: 1px solid var(--color-purple);
  outline-offset: -0.25em;
}

form input[type="submit"] {
  color: #000;
}

form > label {
  display: flex;
  grid-gap: 0.25em;
  position: relative;
}

form > label input,
form > label span {
  transition: 0.5s all cubic-bezier(0.5,0,0,1);
}

form > label span {
  position: absolute;
  opacity: 0;
  right: -0.125em;
}

form > label:hover,
form > label:hover * {
  cursor: pointer;
}

form > label:hover input {
  margin-right: 1em;
}

form > label:hover span {
  opacity: 1;
  right: 0.825em;
}

/*
========================
NOTICE
========================
*/

.notice {
  opacity: 0;
  transform: translateY(-10%);
  transition: 0.5s all cubic-bezier(0.5,0,0,1);
  max-width: 18em;
}

.notice p {
  font-size: 0.625em;
  text-align: center;
}

form:focus-within ~ .notice,
form:hover ~ .notice {
  opacity: 0.4;
  transform: translateY(0%);
}