* {
  box-sizing: border-box;
}

:root {
  --color: hsl(0, 0%, 90%);
  --bg: hsl(255, 50%, 20%);
  --container: hsl(0, 0%, 20%);
  --hue: hsl(255, 50%, 20%);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Roboto', sans-serif;
}

h1 {
  margin-bottom: 0;
  font-weight: bold;
}
h2 {
  font-size: 1.5rem;
}
#app {
  padding: 2rem 3rem;
  min-height: 100vh;
  margin-top: 150px;
  display: flex;
  align-items: center;
  /* justify-content: center; */
  flex-direction: column;
  transform-style: preserve-3d;
  perspective: 1000px;
  perspective-origin: 50% 25%;
}

#app > * + * {
  margin-bottom: 2rem;
}

article {
  max-width: 600px;
}

footer {
  font-size: 0.875rem;
}

.motion-element {
  height: 40px;
  width: 40px;
  position: absolute;
  top: 0%;
  left: 0%;
  offset-path: path(var(--path));
  animation: travel 2s infinite var(--animation-direction, normal) linear;
  transform-style: var(--transform-style, 'none');
  transform: translate3d(0, 0, 20px);
}
.motion-element__side {
  background: hsla(90,100%,50%,0.1);
  border: 2px hsl(90, 100%, 50%) solid;
  height: 100%;
  position: absolute;
  width: 100%;
}
.motion-element__side:nth-of-type(1) {
  transform: translate3d(0, 0, 20px);
}
.motion-element__side:nth-of-type(2) {
  transform: translate3d(0, 0, -20px);
}
.motion-element__side:nth-of-type(3) {
  transform: rotateX(90deg) translate3d(0, 0, -20px);
}
.motion-element__side:nth-of-type(4) {
  transform: rotateX(90deg) translate3d(0, 0, 20px);
}
.motion-element__side:nth-of-type(5) {
  transform: rotateY(90deg) translate3d(0, 0, 20px);
}
.motion-element__side:nth-of-type(6) {
  transform: rotateY(-90deg) translate3d(0, 0, 20px);
}

.container__wrapper {
  padding: 25px;
  height: 25vmin;
  width: 25vmin;
  min-width: 200px;
  min-height: 200px;
  overflow: var(--overflow, hidden);
  transform-style: preserve-3d;
  margin-bottom: 2rem;
  border: 4px solid var(--color);
  resize: both;
}

.container {
  height: 100%;
  width: 100%;
  position: relative;
  transform-origin: bottom center;
  transform-style: preserve-3d;
  transform: rotateX(calc(var(--rotation, 0) * 1deg));
}
button {
  padding: 8px 16px;
}
details {
  width: 100%;
}
summary {
  margin-bottom: 1rem;
  padding: 1rem 0;
}
.container path {
  fill: none;
  stroke: hsl(255, 100%, 50%);
  stroke-width: 4px;
  transition: stroke 0.25s ease;
}

.repo-link {
  position: fixed;
  top: 1rem;
  right: 1rem;
  height: 44px;
  width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.container svg {
  display: var(--svg-display, 'block');
}
.repo-link svg {
  height: 24px;
  width: 24px;
}

.repo-link path {
  fill: white;
}

svg {
  height: 100%;
  width: 100%;
}
label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: bold;
}
input {
  display: block;
}
[type=text],
[type=number] {
  margin: 0;
  padding: 8px 16px;
  width: 100%;
}
a {
  color: hsl(0, 100%, 100%);
}
p {
  line-height: 1.5;
  text-align: left;
  width: 100%;
}
form {
  display: grid;
  grid-gap: 20px;
}
.form-field {
  margin-bottom: 1.25rem;
}
.form-field--grid {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  grid-gap: 20px 10px;
}
@-moz-keyframes travel {
  from {
    offset-distance: 0%;
  }
  to {
    offset-distance: 100%;
  }
}
@-webkit-keyframes travel {
  from {
    offset-distance: 0%;
  }
  to {
    offset-distance: 100%;
  }
}
@-o-keyframes travel {
  from {
    offset-distance: 0%;
  }
  to {
    offset-distance: 100%;
  }
}
@keyframes travel {
  from {
    offset-distance: 0%;
  }
  to {
    offset-distance: 100%;
  }
}
