:root {
  /* primary */
  --light-red: hsl(0, 100%, 67%);
  --orange-yellow: hsl(39, 100%, 56%);
  --green-teal: hsl(166, 100%, 37%);
  --cobalt-blue: hsl(234, 85%, 45%);

  /* gradients */
  --light-slate-blue: hsl(252, 100%, 67%);
  --light-royal-blue: hsl(241, 81%, 54%);
  --violet-blue: hsla(256, 72%, 46%, 1);
  --persian-blue: hsla(241, 72%, 46%, 0);

  /* neutral */
  --white: hsl(0, 0%, 100%);
  --pale-blue: hsl(221, 100%, 95%);
  --light-lavender: hsl(241, 100%, 89%);
  --dark-gray-blue: hsl(224, 30%, 27%);
}

*,
*::before,
*::after {
  padding: 0;
  margin: 0;
}

html {
  font-size: 62.5%;
  box-sizing: border-box;
  scroll-behavior: smooth;
}

@font-face {
  font-family: "HankenGrotesk";
  src: url(./assets/fonts/HankenGrotesk-VariableFont_wght.ttf);
  font-weight: normal;
}

body {
  font-family: HankenGrotesk, sans-serif;
}

h4,
p {
  font-size: 1.8rem;
}

h4,
p,
span,
button {
  color: var(--white);
  font-weight: bold;
}

ol {
  list-style: none;
}

/* main */

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

  height: 100vh;
  max-width: 144rem;
  margin: 0 auto;
}

.container {
  display: flex;

  box-shadow: 10px 10px 3rem var(--pale-blue);
}

@media only screen and (max-width: 600px) {
  .container {
    flex-direction: column;
  }
}

/* result & summary sections */

.result,
.summary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3rem;

  width: 30rem;
  height: 38rem;
  padding: 2.4rem 0rem;
}

/* result section */

.result {
  background: linear-gradient(var(--light-slate-blue), var(--light-royal-blue));
  border-radius: 2.5rem;

  text-align: center;
}

.result .title {
  color: var(--light-lavender);
}

.total-container {
  display: flex;
  justify-content: center;
  align-items: center;

  width: 16rem;
  height: 16rem;
  background: linear-gradient(var(--violet-blue), var(--persian-blue));
  border-radius: 50%;
}

.total {
  color: var(--light-lavender);

  max-width: 6rem;
}

.total span {
  color: var(--white);
  font-size: 5rem;
}

.rating span {
  display: block;

  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.rating p {
  font-size: 1.4rem;
  max-width: 20rem;
  color: var(--light-lavender);
}

/* summary section */

.summary {
  border-radius: 0 2.5rem 2.5rem 0;
}

.summary .title {
  align-self: flex-start;
  color: var(--dark-gray-blue);
  padding-left: 2.4rem;
}

.metrics {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

.metric {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 7rem;

  max-width: 24rem;
  padding: 1.5rem;
  border-radius: 0.8rem;
}

.metric div {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.metric img {
  display: inline-block;
}

.reaction {
  background-color: hsla(0, 100%, 67%, 0.07);
}

.reaction .category {
  color: var(--light-red);
}

.memory {
  background-color: hsla(39, 100%, 56%, 0.07);
}

.memory .category {
  color: var(--orange-yellow);
}

.verbal {
  background-color: hsla(166, 100%, 37%, 0.07);
}

.verbal .category {
  color: var(--green-teal);
}

.visual {
  background-color: hsla(234, 85%, 45%, 0.07);
}

.visual .category {
  color: var(--cobalt-blue);
}

.score {
  color: var(--light-lavender);
}

.score span {
  color: var(--dark-gray-blue);
}

button {
  background: var(--dark-gray-blue);
  border: 0;
  border-radius: 2.5rem;
  width: 26.5rem;
  padding: 1.8rem 0;

  cursor: pointer;
  position: relative;
  z-index: 1;
}

button::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 2.5rem;
  color: var(--white);
  background: linear-gradient(var(--light-slate-blue), var(--light-royal-blue));
  opacity: 0;
  transition: opacity 0.3s linear;
  z-index: -1;
}

button:hover::before {
  opacity: 1;
}

@media only screen and (max-width: 600px) {
  .result,
  .summary {
    gap: 1rem;

    height: 30rem;
  }
  .metrics {
    gap: 1rem;
  }
}

@media only screen and (max-height: 660px) {
  main {
    align-items: flex-start;
  }

  .result,
  .summary {
    gap: 1rem;

    max-width: 27.5rem;
    height: 24rem;
  }

  .total-container {
    width: 8rem;
    height: 8rem;
  }

  .total span {
    color: var(--white);
    font-size: 3rem;
  }
}
