.ending-after {
  display: none;
  margin-top: 20px;
}
.ending-after .btn {
  display: inline-block;
}
.ending-after.show {
  display: block;
}
.ending-cta {
  background-color: #f5efe6;
  border: 1px solid #d9c4a2;
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 16px;
  text-align: center;
}
.ending-cta-title {
  font-size: 18px;
  font-weight: 600;
  color: #82687b;
  margin: 0 0 8px;
}
.ending-cta-text {
  font-size: 14px;
  color: #6b5a3a;
  margin: 0 0 16px;
}
.ending-cta-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.ending-cta .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 260px;
  font-weight: 600;
  padding: 10px 32px;
  border-width: 2px;
  border-style: solid;
  border-radius: 4px;
  font-size: 15px;
  text-decoration: none;
  transition: 0.2s ease-in-out;
  line-height: 1.4;
}
.ending-cta .btn-brown {
  background-color: #d6c09b;
  border-color: #d2b990;
  color: #fff;
}
.ending-cta .btn-brown:hover {
  background-color: #dcc9a9;
  border-color: #d2b990;
  color: #fff;
}
.ending-cta-retry {
  display: inline;
  background: transparent;
  border: 0;
  padding: 0;
  font-family: inherit;
  line-height: 1.4;
  -webkit-appearance: none;
  appearance: none;
  font-size: 13px;
  color: #82687b;
  text-decoration: underline;
  cursor: pointer;
}
.ending-cta-retry:hover {
  color: #5a4655;
}

.game-title {
  color: #fff;
  line-height: 47px;
  font-size: 34px;
  font-weight: 400;
  text-shadow: 1px 1px 2px #82687b;
}

.step-title {
  color: #82687b;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.step-title span {
  width: 35px;
  height: 35px;
  display: block;
  margin-left: 10px;
  text-align: center;
  font-size: 14px;
  color: #fff;
  line-height: 34px;
  background-color: #d6c09b;
  border: 2px solid #d2b990;
  border-radius: 50%;
}

.result-title {
  color: #82687b;
  font-size: 18px;
  font-weight: 600;
}

.game-carpet {
  background: url("../img/carpet.png");
  background-color: #dcc9a9;
  border: 1px solid #d9c4a2;
  padding: 10px;
  position: relative;
  overflow: hidden;
  border-radius: 7px;
  height: 650px;
}

.game-actions .card-list {
  height: 420px;
}
.game-actions .game-start {
  text-align: center;
  margin-right: 10px;
}
.game-actions .game-start .game-title {
  margin-top: 10px;
}

.game-result {
  display: none;
  position: relative;
}
.game-result .result-loader {
  display: flex;
  background-color: #e9e0d2;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 1;
  transition: opacity 1s;
}
.game-result .result-loader.hide {
  opacity: 0;
}
.game-result.show {
  display: block;
}

.game-progress {
  display: flex;
  justify-content: center;
}
.game-progress .progress-container {
  width: 150px;
  height: 150px;
  margin-top: 110px;
}

@media screen and (max-width: 920px) {
  .game-actions .game-start {
    margin-right: 0;
  }
}
@media screen and (max-width: 820px) {
  .game-start .btn {
    min-width: 160px;
  }
  .game-start .btn span {
    display: none;
  }
}
@media screen and (max-width: 520px) {
  .game-start .btn {
    min-width: unset;
    padding: 7px 20px;
  }
}
.game-step {
  position: absolute;
  z-index: -1;
  top: 10px;
  bottom: 10px;
  right: -440px;
  width: 395px;
  padding: 20px;
  background-color: transparent;
  transition: background-color 0.7s, right 1s, box-shadow 4s, border-radius 4s;
}
.game-step.show {
  z-index: 99;
  right: 10px;
  background-color: #e9e0d2;
  box-shadow: -1px 2px 6px 1px rgba(0, 0, 0, 0.3) inset;
  border-radius: 14px;
}
.game-step .step-group {
  display: none;
}
.game-step .step-group.show {
  display: block;
}
.game-step .step-group .card-list {
  display: flex;
  min-height: 160px;
  padding: 5px;
  border: 2px dotted #dcc9a9;
  border-radius: 7px;
}
.game-step .step-group .game-card {
  margin-left: 5px;
  border-color: #f5d695;
}
.game-step .step-group .game-card:first-of-type {
  margin-left: 0;
}
.game-step .step-actions {
  margin-top: 40px;
  text-align: right;
}
.game-step .step-title {
  margin-bottom: 5px;
}
.game-step .step-text {
  color: #82687b;
  font-size: 18px;
  margin-top: 5px;
  margin-bottom: 5px;
  font-weight: 400;
  display: none;
}
.game-step .step-text span {
  display: block;
}
.game-step .step-text.show {
  display: block;
}
.game-step .step-cards.hide {
  display: none;
}
.game-step .result-title {
  margin-top: 0;
}

@media screen and (max-width: 920px) {
  .game-step {
    top: unset;
    width: unset;
    bottom: -270px;
    right: 10px !important;
    left: 10px;
    height: 225px;
    transition: background-color 0.7s, bottom 1s, box-shadow 4s, border-radius 4s, height 0.3s ease-in;
  }
  .game-step.show {
    bottom: 10px;
  }
  .game-step .step-text span {
    display: inline;
  }
  .game-step .step-title,
.game-step .game-progress {
    display: none;
  }
  .game-step.end {
    overflow-y: scroll;
    height: 300px;
  }
}
@media screen and (max-width: 820px) {
  .step-group .card-list {
    min-height: 155px;
  }
  .step-group .game-card {
    width: 80px;
    height: 140px;
  }
  .step-group .step-text {
    margin-top: 0;
  }
}
@media screen and (max-width: 640px) {
  .game-step.end {
    height: 400px;
  }
}
@media screen and (max-width: 520px) {
  .game-step {
    bottom: -295px;
    height: 250px;
  }
  .game-step.end {
    height: 610px;
  }
  .game-step .step-group .game-card {
    margin-left: -15px;
  }
}
.game .btn {
  font-weight: 600;
  padding: 7px 30px;
  border: 2px solid transparent;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
  transition: 0.2s ease-in-out;
}
.game .btn.disabled, .game .btn:disabled {
  cursor: default;
}
.game .btn.hide {
  display: none;
}
.game .btn.left {
  border-radius: 10px 0 0 10px;
}
.game .btn.right {
  border-radius: 0 10px 10px 0;
}

.game .btn-light {
  background-color: #fff;
  border-color: #e9e0d2;
  color: #262626;
  box-shadow: 2px 2px 4px 0 rgba(0, 0, 0, 0.2);
}
.game .btn-light:hover {
  background-color: #f1f1f1;
}
.game .btn-light.disabled, .game .btn-light:disabled {
  background-color: #ccc;
}

.game .btn-brown {
  background-color: #d6c09b;
  border-color: #d2b990;
  color: #fff;
}
.game .btn-brown:hover {
  background-color: #dcc9a9;
}
.game .btn-brown.right-arrow::after {
  display: inline-block;
  content: ">>";
  margin-left: 7px;
  font-size: 14px;
  font-weight: 300;
  color: #fff;
}

.game .input {
  border: 1px solid #dcc9a9;
  border-radius: 4px;
  width: 100%;
  font-size: 16px;
  font-weight: 500;
  color: #82687b;
  padding: 15px 20px;
  width: calc(100% - 40px);
}
.game .input:hover {
  border-color: #d6c09b;
}

.game .radio-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 200px;
  gap: 20px;
  margin-bottom: 10px;
  cursor: pointer;
}
.game .radio-item:last-of-type {
  margin-bottom: 0;
}

@media screen and (max-width: 920px) {
  .game .input {
    padding: 10px 20px;
  }
}
.card-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.card-list.circle-cards {
  position: relative;
  top: 33px;
  left: calc(50% - 47px);
  transition: left 1s ease-in;
}
.card-list.circle-cards.left {
  left: calc(50% - 265px);
}
.card-list.circle-cards .game-card {
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: center 290px;
}

.game-card {
  width: 90px;
  height: 160px;
  background-color: #ebebeb;
  border: 1px solid #e6e6e6;
  border-radius: 7px;
}
.game-card.active {
  border-color: transparent;
  box-shadow: 1px 1px 4px 0 rgba(0, 0, 0, 0.05);
  transition: transform-origin 1s ease-out;
}

.game-card img {
  width: 100%;
  height: 100%;
}

.game-card.active:not(.selected) {
  cursor: pointer;
}
.game-card.active:not(.selected):not(:last-child) img {
  transition: 0.2s ease-in;
}
.game-card.active:not(.selected):not(:last-child) img:hover {
  transform: scale(1.1) rotate(-5deg) translateX(-2px);
}

@media screen and (max-width: 1100px) {
  .card-list.circle-cards .game-card:not(.active) {
    transform-origin: center 190px !important;
  }
}
@media screen and (max-width: 520px) {
  .card-list .circle-cards {
    left: calc(50% - 40px);
  }
  .card-list .circle-cards.left {
    left: calc(50% - 265px);
  }
  .card-list .circle-cards .game-card {
    width: 80px;
    height: 140px;
  }
  .card-list .circle-cards .game-card:not(.active) {
    transform-origin: center 150px !important;
  }
}
.inter-loader {
  position: relative;
  display: block;
  width: 180px;
  height: 200px;
  margin: auto;
  background-color: #e6dbcb;
}
.inter-loader:after {
  position: absolute;
  top: 15px;
  left: 15px;
  content: "";
  width: calc(100% - 30px);
  height: 100%;
  background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3) 50%, transparent 100%), radial-gradient(circle 55px, #dfceb0 100%, transparent 0), linear-gradient(#dfceb0 16px, transparent 0), linear-gradient(#dfceb0 24px, transparent 0);
  background-repeat: no-repeat;
  background-size: 75px 175px, 100% 110px, 60% 14px, 80% 14px;
  background-position: -205px 0, center 10px, center 125px, center 145px;
  animation: anime-loader 1s linear infinite;
}

@keyframes anime-loader {
  to {
    background-position: 205px 0, center 10px, center 125px, center 145px;
  }
}
