:root {
  --black: #04030f;
  --purple: #5f1a37;
  --lightpurple: #9b2455;
  --darkpurple: #580e2d;
  --violet: #776885;
  --lightblue: #73c2be;
  --turquoise: #73eedc;
}

body {
  min-height: 100dvh;
  background: var(--black);
  color: #eee;
  font-family: 'Inter', Arial, Helvetica, sans-serif;
  margin: 0;
  padding: 2rem 4rem;
  box-sizing: border-box;
  font-weight: 400;
}

h1 {
  font-weight: 700;
}

header {
  width: 100%;
  height: 5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

main {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  grid-template-rows: auto auto auto;
  grid-template-areas:
    'lh . rh'
    'lb m rb'
    'lc . rc';
  gap: 1rem;
  align-items: center;
}

#left-head {
  grid-area: lh;
}
#left-box {
  grid-area: lb;
}
#left-copy {
  grid-area: lc;
}

#right-head {
  grid-area: rh;
}
#right-box {
  grid-area: rb;
}
#right-copy {
  grid-area: rc;
}

#switch {
  grid-area: m;
}

@media (max-width: 800px) {
  main {
    grid-template-rows: auto 1fr auto auto 1fr;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      'lh lc'
      'lb lb'
      'm m'
      'rh rc'
      'rb rb';
  }
}

textarea {
  height: 10rem;
  background: #fff1;
  border: 1px solid #fff2;
  transition: 150ms;
  transition-property: background;
  border-radius: 0.7rem;
  color: white;
  font: inherit;
  resize: none;
  padding: 0.75rem 1rem;
}

textarea:focus {
  outline: 3px solid var(--lightblue);
  background: #fff2;
}

button {
  background: var(--purple);
  transition: 150ms;
  transition-property: background;
  color: white;
  border: 1px solid #fff2;
  border-radius: 0.5rem;
  padding: 0.5rem 1rem;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

button:focus {
  outline: 2px solid white;
}

button:hover {
  background: var(--lightpurple);
}

button:active {
  background: var(--darkpurple);
}

button.copy {
  justify-self: right;
}
