:root {
  --blue-200: hsl(243, 100%, 93%);
  --blue-850: hsl(228, 56%, 26%);
  --blue-950: hsl(229, 57%, 11%);
  --grayish-blue: hsl(229, 7%, 55%);
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

body {
  background: url("./images/bg-mobile.png");
  background-repeat: no-repeat;
  object-fit: contain;
  font-family: Raleway, Courier, monospace;
}

main {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

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

.images {
  width: 100%;
  background-color: var(--blue-850);
  padding: 40px 120px 40px 40px;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  border-radius: 10px 100px 10px 10px;
  -webkit-border-radius: 10px 100px 10px 10px;
  -moz-border-radius: 10px 100px 10px 10px;
  -ms-border-radius: 10px 100px 10px 10px;
  -o-border-radius: 10px 100px 10px 10px;
}

.logo {
  align-self: flex-start;
}

.icons {
  display: flex;
  gap: 1rem;
}

.icon {
  padding: 12px;
  background-color: var(--blue-950);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  border-radius: 10px;
  -webkit-border-radius: 10px;
  -moz-border-radius: 10px;
  -ms-border-radius: 10px;
  -o-border-radius: 10px;
}

.icon svg {
  flex-shrink: 0;
}

.state {
  width: 100%;
  background: hsl(228, 56%, 26%);
  padding: 40px;
  max-width: 540px;
  position: relative;
  border-radius: 12px;
  -webkit-border-radius: 12px;
  -moz-border-radius: 12px;
  -ms-border-radius: 12px;
  -o-border-radius: 12px;
}

.state-info {
  display: block;
  color: hsl(243, 100%, 93%);
  font-size: 14px;
  margin-bottom: 16px;
  text-align: center;
}

.state-info strong {
  font-weight: 700;
}

.group {
  margin-bottom: 10px;
}

.progress-container {
  background: var(--blue-950);
  height: 20px;
  padding: 3px;
  margin-bottom: 8px;
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  -webkit-border-radius: 10px;
  -moz-border-radius: 10px;
  -ms-border-radius: 10px;
  -o-border-radius: 10px;
}

.progress-bar {
  height: 100%;
  position: relative;
  background: linear-gradient(to right, hsl(6, 100%, 80%), hsl(335, 100%, 65%));
  width: 81.5%;
  border-radius: 8px;
  -webkit-border-radius: 8px;
  -moz-border-radius: 8px;
  -ms-border-radius: 8px;
  -o-border-radius: 8px;
}

.progress-bar::after {
  content: "";
  position: absolute;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  background: white;
  border-radius: 50%;
  -webkit-border-radius: 50%;
  -moz-border-radius: 50%;
  -ms-border-radius: 50%;
  -o-border-radius: 50%;
}

.quota {
  display: flex;
  justify-content: space-between;
  color: hsl(243, 100%, 93%);
  font-size: 12px;
  font-weight: 700;
}

.remaining {
  position: absolute;
  width: 182px;
  left: 50%;
  display: flex;
  align-items: center;
  gap: 12px;
  background: white;
  color: hsl(229, 7%, 55%);
  padding: 14px 30px;
  margin-top: 10px;
  font-weight: 700;
  font-size: 12px;
  text-align: center;
  border-radius: 8px;
  -webkit-border-radius: 8px;
  -moz-border-radius: 8px;
  -ms-border-radius: 8px;
  -o-border-radius: 8px;
  transform: translate(-50%, 0);
  -webkit-transform: translate(-50%, 0);
  -moz-transform: translate(-50%, 0);
  -ms-transform: translate(-50%, 0);
  -o-transform: translate(-50%, 0);
}

.remaining-quota {
  font-weight: 700;
  word-spacing: 0.5px;
  font-size: 40px;
  color: var(--blue-950);
  margin-bottom: 4px;
  line-height: 1;
}

@media screen and (min-width: 768px) {
  body {
    background: url("./images/bg-desktop.png");
    background-repeat: no-repeat;
    object-fit: contain;
    background-color: var(--blue-950);
    background-position: bottom center;
    background-size: 100% auto;
    min-height: 100vh;
  }

  .container {
    max-width: 920px;
    flex-direction: row;
    align-items: flex-end;
  }

  .images {
    max-width: 350px;
  }

  .state {
    width: 540px;
  }

  .remaining {
    margin-top: 0;
    top: 0;
    left: 75%;
    top: -50px;
    border-radius: 8px 8px 0 8px;
    -webkit-border-radius: 8px 8px 0 8px;
    -moz-border-radius: 8px 8px 0 8px;
    -ms-border-radius: 8px 8px 0 8px;
    -o-border-radius: 8px 8px 0 8px;
  }

  .remaining::after {
    position: absolute;
    content: "";
    bottom: -22px;
    right: 0px;
    border-left: 22px solid transparent;
    border-right: 0;
    border-top: 22px solid white;
  }
}
