:root {
  --clr-blue: #15616d;
  --clr-dark-blue: #001524;
  --clr-creamy: #ffecd1;
  --clr-orange: #ff7d00;
  --clr-brown: #78290f;
}

/* CSS Reset */

/* 1. Use a more-intuitive box-sizing model */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* 2. Remove default margin */
* {
  margin: 0;
  padding: 0;
}

body {
  /* 4. Add accessible line-height */
  line-height: 1.5;
  /* 5. Improve text rendering */
  -webkit-font-smoothing: antialiased;
}

/* 6. Improve media defaults */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

/* 7. Inherit fonts for form controls */
input,
button,
textarea,
select {
  font: inherit;
}

/* 8. Avoid text overflows */
p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

/* 9. Improve line wrapping */
p {
  text-wrap: pretty;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}

/*
    10. Create a root stacking context
  */
#root,
#__next {
  isolation: isolate;
}

body {
  background-color: var(--clr-creamy);
  font-family: 'Oswald', sans-serif;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  font-weight: bold;
}

/* Layout */

.container {
  width: 90rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.header {
  display: flex;
  justify-content: center;
  align-items: center;
}

.icons {
  display: flex;
  margin-top: -6px;
}

.split {
  display: flex;
  width: 30rem;
  justify-content: space-between;
  text-align: center;
}

.columns {
  display: flex;
  margin-top: 1rem;
  gap: 1rem;
  width: 40rem;
  justify-content: space-between;
}

/* ELEMENTS */

.buttons {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.btn {
  padding: 12px 45px;
  border: none;
  border-radius: 20px;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--clr-creamy);
}

.btn--reset {
  background-color: var(--clr-orange);
}

.btn--play {
  background-color: var(--clr-blue);
}

.title {
  font-family: 'Indie Flower', cursive;
  font-size: 2.5rem;
}
.name {
  color: var(--clr-blue);
  padding: 4px;
  border: 2px solid var(--clr-blue);
  font-size: 1.125rem;
}

.user-score,
.computer-score {
  font-size: 1.25rem;
  color: var(--clr-orange);
}

/* EFFECTS */

#overlay {
  position: fixed;
  display: none;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 2;
  /* cursor: pointer; */
}

.overlay-box {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.375rem;
  background-color: #eeece9;
  padding: 30px 40px;
  width: 23rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  border-radius: 4px;
  box-shadow: rgba(0, 0, 0, 0.12) 0px 1px 3px, rgba(0, 0, 0, 0.24) 0px 1px 2px;
}

.overlay-box .icons {
  gap: 25px;
  cursor: pointer;
}

.overlay-box .icons img {
  transition-duration: 500ms;
}

.overlay-box .icons img:hover {
  scale: 1.2;
}

.gesture {
  filter: brightness(0) saturate(100%) invert(63%) sepia(39%) saturate(7162%)
    hue-rotate(360deg) brightness(105%) contrast(107%);
  scale: 3.55;
  margin-inline: 1.5rem;
}

.win-message {
  color: var(--clr-blue);
  padding: 7px;
  background-color: rgba(255, 125, 0, 0.1);
  border-radius: 4px;
  text-align: center;
}

.win-message.hidden {
  display: none;
}

.hidden {
  display: none;
}


.tie-message {
  color: var(--clr-orange);
  background: rgba(21, 97, 109, 0.08);
  border-radius: 4px;
  padding: 6px 10px;
  text-align: center;
  font-size: 1.125rem;
}

/* Responsivness */

@media (max-width: 700px) {
  body {
    padding: 16px;
  }

  .container {
    width: 100%;
    max-width: 700px;
    gap: 1.7rem;
  }

  .title {
    font-size: clamp(1.75rem, 8vw, 2.25rem);
  }

  .split {
    width: 100%;
    max-width: 520px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
    padding: 0 4px;
  }
  .player {
    background: rgba(21, 97, 109, 0.06);
    border: 1px solid rgba(21, 97, 109, 0.25);
    border-radius: 10px;
    padding: 6px 10px;
  }
  .name {
    font-size: 0.938rem;
    padding: 2px 6px;
  }
  .user-score,
  .computer-score {
    font-size: 1.125rem;
  }

  .columns {
    width: 100%;
    align-items: center;
  }

  .gesture {
    scale: 0.7;
    width: clamp(96px, 28vw, 150px);
    margin-inline: 0;
  }

  .buttons {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .btn {
    width: 100%;
    padding: 12px 0;
    font-size: 1rem;
    border-radius: 14px;
  }

  .overlay-box {
    width: 19rem;
    padding: 22px;
    gap: 14px;
    font-size: 1rem;
  }
}
