@import url("https://fonts.googleapis.com/css2?family=Red+Hat+Display:ital,wght@0,300..900;1,300..900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Rajdhani:wght@300;400;500;600;700&family=Urbanist:ital,wght@0,100..900;1,100..900&display=swap");

:root {
  --blue-foreground: #b7e6ff;
  --blue-foreground-darker: #92bcd5;
  --blue-background: #091423;
  --blue-background-light: #112542;
  --blue-complement: #FFF4B7;

  --green-foreground: #cfffb7;
  --green-foreground-darker: #a1d38c;
  --green-background: #132309;
  --green-background-light: #1c330c;
  --green-complement: #FFF4B7;

  --yellow-foreground: #FFF4B7;
  --yellow-foreground-darker: #d1c689;
  --yellow-background: #231c09;
  --yellow-background-light: #37280e;
  --yellow-complement: #FFF4B7;

  --foreground: var(--green-foreground);
  --foreground-darker: var(--green-foreground-darker);
  --background: var(--green-background);
  --background-light: var(--green-background-light);
  --complement: var(--green-complement);
  --white: #fff8e6;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--background);
  transition: background-color 300ms;
  margin-bottom: 80px;
}

.card, #header {
  margin: auto;
  @media only screen and (max-width: 500px) {
    width: 90%;
  }

  @media only screen and (min-width: 500px) {
    width: 60vw;
  }
}

.card {
  display: none;
  opacity: 0;
  transition: opacity 300ms, display 300ms;
  padding: 20px 0;
}

progress {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  border: 1px solid var(--foreground);
  background-color: var(--background);
  width: 100%;
  height: 10px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 300ms, visibility 300ms;

  &::-webkit-progress-bar {
    background-color: var(--background);
  }

  &::-webkit-progress-value {
    background-color: var(--foreground);
    transition: width 500ms;
  }

  &::-moz-progress-bar {
    background-color: var(--foreground);
    transition: width 500ms;
  }
}

.time-progress {
  opacity: 1;
  visibility: visible;
}

#survey-name {
  font-family: "Rajdhani", sans-serif;
  font-weight: 100;
  padding: 60px 0 0 0;
  color: var(--complement);
  font-size: 25pt;
  transition: color 300ms;
}

.survey-prompt {
  font-family: "Urbanist", sans-serif;
  font-weight: 300;
  color: var(--complement);
  line-height: 1.4;
  transition: color 300ms;
}

h1, h3 {
  font-family: "Rajdhani", sans-serif;
  font-weight: 600;
  transition: color 300ms;
  color: var(--foreground);
}

h2 {
  font-family: "Urbanist", sans-serif;
  transition: color 300ms;
  color: var(--foreground);
  font-size: 22pt;
  font-weight: 300;
}

h3 {
  font-size: 20pt;
}

p, dd {
  font-family: "Urbanist", sans-serif;
  transition: color 300ms;
  color: var(--foreground);
  font-size: 16pt;
  line-height: 1.5;
  margin-block-start: 0;
  margin-block-end: 0;
  margin: 20px 0;
  font-weight: 300;
}

dd {
  display: list-item;
  list-style-type: "\00BB";
  border-radius: 0.3ch;
  padding-inline-start: 1ch;
}

dl {
  margin-left: 15px;
}

.response-area {
  display: block;
  width: 100%;
  font-size: 16pt;
  font-weight: 400;
  font-family: "Red Hat Display", sans-serif;
  resize: none;
  color: var(--foreground);
  background-color: var(--background-light);
  outline: 0;
  border: none;
  padding: 15px;
  border-radius: 0 0 5px 5px;
  line-height: 1.4;
  transition: color 300ms, background-color 300ms;
  box-sizing: border-box;
}

::placeholder {
  color: var(--foreground);
  opacity: 0.2;
  transition: color 300ms;
}

button {
  font-family: "Rajdhani", sans-serif;
  font-weight: 500;
  filter: brightness(1.5);
  font-size: 13pt;
  padding: 10px 20px;
  border-radius: 5px;
  transition: color 300ms, opacity 300ms;
  color: var(--foreground-darker);
  background-color: var(--background);
  outline: 0;
  border: 1px solid var(--background-light);

  &:not([disabled]):hover {
    cursor: pointer;
    opacity: 0.7;
  }

  &[disabled]:hover {
    cursor: wait;
  }
}

.button-group {
  margin-top: 30px;
  display: flex;
  justify-content: space-between;
}

.field {
  padding: 15px;
  display: flex;
  flex-direction: column;
}

label {
  color: var(--foreground);
  font-family: "Rajdhani", sans-serif;
  font-size: 16pt;
}

select, input[type="text"], input[type="email"] {
  appearance: none;
  font-family: "Urbanist", sans-serif;
  background: var(--background);
  color: var(--foreground);
  padding: 5px 10px;
  border: 1px solid var(--foreground);
  border-radius: 2px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: 300ms;
  text-align: center;
  font-size: 12pt;
  outline: 0;

  &:hover {
    background: var(--foreground);
    color: var(--background);
    cursor: pointer;
  }
}

input[type="range"] {
  margin: 30px 0 10px 0;
  -webkit-appearance: none;
  width: 100%;
  height: 15px;
  background: var(--background);
  border: 1px solid var(--foreground);
  outline: none;
  opacity: 0.9;
  -webkit-transition: 300ms;
  transition: opacity 300ms;

  &:hover {
    opacity: 1;
  }

  &::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 25px;
    height: 25px;
    background: var(--foreground);
    cursor: pointer;
  }

  &::-moz-range-thumb {
    width: 25px;
    height: 25px;
    background: var(--foreground);
    cursor: pointer;
  }
}

.time-card {
  margin-top: 20vh;
  margin-bottom: 50px;
  opacity: 1;
  transition: opacity 800ms;

  p {
    font-size: 14pt;
    opacity: 0.8;
    transition: opacity 300ms;
  }

  progress {
    opacity: 0.5;
    transition: opacity 300ms;
  }

  &:hover p {
    opacity: 1;
  }

  &:hover progress {
    opacity: 0.8;
  }
}

#card-9 .subscribe-prompt {
  padding: 20px 10px;
  border-radius: 5px;
  background-color: var(--background-light);
  border: 1px solid var(--foreground);
  display: flex;
  flex-direction: column;

  > * {
    margin: 5px 10px;
  }

  input {
    margin-right: 10px;
  }

  button {
    background-color: var(--background);
    filter: brightness(1.8);
    margin: 10px 0;
  }
}

a, a:visited, a:active {
  color: var(--foreground);
  text-decoration: none;
  border-bottom: 1px solid;
  font-weight: inherit;
  transition: font-weight 300ms;
}

a:hover {
  font-weight: 500;
}