:root {
  --color-background: #FD3939;
  --color-text: #363636;
  --color-primary: #FD3939;

  --layout-negative: -1;
  --layout-default: 1;
  --layout-interaction: 5;
  --layout-dropdown: 10;
  --layout-sticky: 100;
  --layout-tooltip: 500;
  --layout-modal: 1000;
}


@font-face {
  font-family: "TT Runs";
  src: url("../fonts/TT_Runs/DemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "TT Smalls";
  src: url("../fonts/TT_Smalls/Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

html {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  font-family: "TT Smalls", sans-serif;
  color: var(--color-text);
  font-size: 18px;
  overflow-x: hidden;
}

.main {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: min-content;
  padding: 40px;

  &::after {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-position: 50% 50%;
    background-repeat: no-repeat;
    background-size: cover;
    background-image: image-set(
      url("../images/main-background.webp") type("image/webp"),
      url("../images/main-background.jpg") type("image/jpg")
    );
    z-index: var(--layout-negative);
  }

  @media (max-width: 1024px) {
    padding: 15px 0 0;
  }
  @media (max-width: 768px) {
    height: auto;
  }

  .content {
    position: relative;
    display: flex;
    width: 100%;
    height: 100%;
    z-index: var(--layout-default);

    @media (min-width: 1025px) {
      justify-content: space-between;
      align-items: center;
      max-height: clamp(400px, 43.056vw, 620px);
      margin-bottom: 100px;
    }

    @media (max-width: 1024px) {
      flex-direction: column;
      max-width: 520px;
      margin-inline: auto;
      height: auto;
    }
  }

}

.container {
  display: flex;
  align-items: center;
  max-width: 1273px;
  height: 100%;
  padding: 0 20px;
  margin-inline: auto;
}

.button-sound {
  position: fixed;
  top: 40px;
  right: 80px;
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: 50% 50%;
  z-index: var(--layout-interaction);
  opacity: .32;

  @media (max-width: 768px) {
    right: 40px;
  }

}

.button-sound[data-mute="on"] {
  background-image: url("../images/sound-on.svg");
}

.button-sound[data-mute="off"] {
  background-image: url("../images/sound-off.svg");
}

.ball-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex: 0 0 clamp(360px, 53.681vw, 773px);
  border-radius: clamp(17px, 7.53vw /* 32/4.25 */, 32px);
  min-height: 470px;
  background-position: 50% 50%;
  background-repeat: no-repeat;
  background-size: cover;
  background-image: image-set(
    url("../images/container-background.webp") type("image/webp"),
    url("../images/container-background.jpg") type("image/jpg")
  );
  z-index: var(--layout-default);
  overflow: hidden;

  /*Снег*/

  &::before {
    content: "";
    position: absolute;
    bottom: -15px;
    left: 50%;
    width: calc(100% + 100px);
    height: clamp(67px, 6.736vw, 97px);
    background-position: 50% 50%;
    background-repeat: no-repeat;
    background-size: cover;
    background-image: image-set(
      url("../images/snow.webp") type("image/webp"),
      url("../images/snow.png") type("image/png")
    );
    transform: translateX(-50%);

    @media (max-width: 1024px) {
      height: 15%;
      width: 100%;
      bottom: 0;
    }

  }

  @media (max-width: 768px) {
    min-height: 570px;
  }
  @media (max-width: 425px) {
    min-height: 150vw;
  }

}

.ball-wrapper .ball-container {
  position: relative;
  height: 100%;
  width: clamp(335px, 30.556vw, 440px);
  z-index: var(--layout-negative);
}

.ball-wrapper .ball-container .ball {
  position: absolute;
  width: 100%;
  height: 100%;

  img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: 50% 50%;
  }
}

.ball-wrapper .ball-container .texutal {
  position: relative;
  top: 18%;
  display: flex;
  flex-direction: column;
  text-align: center;
  justify-content: center;
  gap: 10px;
  width: 70%;
  height: 45%;
  margin: auto;
  text-wrap: balance;
  opacity: .7;
}

.ball-wrapper .ball-container .texutal .target-title {
  display: block;
  margin-bottom: 1rem;
  line-height: 1.2;
  font-family: "TT Runs", sans-serif;
  font-size: clamp(16px, 1.528vw /* 22/14.4 */, 22px);
  font-weight: 600;
  color: var(--color-primary);
  text-align: center;

  @media (max-width: 425px) {
    font-size: 3.76vw  /* 16/4.25 */;
  }

}

.ball-wrapper .ball-container .texutal .target-desc {
  text-wrap: balance;
  display: block;
  text-align: center;
  font-family: "TT Smalls", sans-serif;
  font-size: clamp(14px, 1.111vw, 16px);
  line-height: 1.5;
  color: #000;

  @media (max-width: 425px) {
    font-size: 3.29vw  /* 14/4.25 */
  ;
  }
}

.card-container {
  position: relative;
  flex: 0 0 clamp(410px, 34.722vw, 500px);
  height: min-content;
  padding: clamp(32px, 5.764vw, 83px) clamp(24px, 3.889vw, 56px);
  border-radius: 29px;
  background: #E9F6FF;
  text-align: center;
  rotate: -12deg;
  transform: translate(calc(clamp(0px, 6.944vw, 100px) * -1), 0);
  z-index: var(--layout-default);

  &::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 1px solid white;
    border-radius: inherit;
    transform: rotate(-6deg);

    @media (max-width: 768px) {
      transform: rotate(4deg);
    }

  }

  @media (max-width: 1240px) {
    bottom: 20px;
  }
  @media (max-width: 1024px) {
    rotate: initial;
    transform: initial;
  }
  @media (max-width: 768px) {
    bottom: 80px;
    width: calc(100% - 20px);
    margin-inline: auto;
  }

}

.card {
  position: relative;
}

.card-container::before,
.card::before,
.card::after {
  content: "";
  position: absolute;
  aspect-ratio: 1/1;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: 50% 50%;
  background-image: image-set(
    url("../images/snowflake.webp") type("image/webp"),
    url("../images/snowflake.png") type("image/png")
  );
  z-index: var(--layout-interaction);
}

.card-container::before {
  top: 0;
  left: 0;
  width: clamp(70px, 9.306vw, 134px);
  transform: translate(-25%, -25%);

  @media (max-width: 768px) {
    transform: translate(-20%, -70%);
  }

}

.card::before {
  right: 0;
  bottom: 0;
  width: clamp(50px, 4.861vw, 70px);
  transform: translate(-50%, 100%);

  @media (max-width: 768px) {
    transform: translate(90%, 20%);
  }
}

.card::after {
  right: 0;
  bottom: 0;
  width: clamp(70px, 6.944vw, 100px);
  transform: translate(60%, 125%);

  @media (max-width: 768px) {
    transform: translate(22%, 89%);
  }
}

.card-title {
  margin-bottom: 12px;
  font-family: "TT Runs", sans-serif;
  font-size: clamp(16px, 1.25vw, 18px);
  font-weight: 600;
  color: #000;

  @media (max-width: 768px) {
    line-height: 1.1;
  }
  @media (max-width: 390px) {
    font-size: 4.1vw  /* 16/3.9 */
  }

}

.card-description {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: center;
  margin-bottom: clamp(30px, 2.5vw, 36px);
  line-height: 1.19rem;
  font-size: clamp(16px, 1.25vw /* 18/14.4 */, 18px);

  @media (max-width: 390px) {
    font-size: 4.1vw  /* 16/3.9 */
  ;
    line-height: 1.2;
    margin-bottom: 7.69vw  /* 30/3.9 */
  ;

  }

}

.card-description + b {
  font-family: "TT Runs", sans-serif;
  font-size: clamp(20px, 1.736vw, 25px);
  font-weight: 600;
  color: var(--color-primary);

  @media (max-width: 390px) {
    font-size: 5.13vw  /* 20/3.9 */
  ;
  }
}

.footer {
  width: 100%;
  height: max-content;
  background: none;
  border-top: 1px solid #595959;
  padding: 20px 0;
  margin-top: 70px;
  z-index: var(--layout-interaction);

  .content {
    display: flex;
    align-items: center;
    gap: 10px 25px;
    width: 100%;
    font-size: 16px;
    flex-wrap: wrap;
  }

  .social-network {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 25px;
    margin-right: auto;

    @media (max-width: 425px) {
      margin-bottom: 10px;
    }
  }

  p {
    color: #595959;
  }

  a {
    color: var(--color-primary);
    @media (hover: hover) {
      &:hover {
        cursor: pointer;
        text-decoration: underline;
        text-decoration-color: inherit;
        text-underline-offset: 0.2rem;
        text-decoration-thickness: 0.01rem;
      }
    }
  }
}


