@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,100..900;1,100..900&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Noto Sans", sans-serif;
}

.begin {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding-top: 20px;
  background-image: url("../assets/Section.png");
  background-size: cover;
  background-position: center;
}

.begin__text {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.begin__tile {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 52.5px;
  font-weight: 400;
  line-height: 52.5px;
  text-align: center;
  margin-top: 10px;

  background: linear-gradient(
    90deg,
    rgba(251, 44, 54, 1) 0%,
    rgb(243, 15, 251) 100%
  );

  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;

  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* MOBILE — как в Figma */
@media (max-width: 640px) {
  .begin__tile {
    font-size: 42px;
    line-height: 52.5px; /* как в фигме */
    max-width: 332px;
    padding-bottom: 7px; /* как в фигме */
  }
}

.begin__desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: center;
  color: rgb(113, 113, 130);

  margin: 10px auto 28px auto;
  max-width: 588px;
  box-sizing: border-box;
}

/* MOBILE — как в фигме */
@media (max-width: 640px) {
  .begin__desc {
    font-size: 15.75px;
    line-height: 24.5px;
    max-width: 332px;
    margin: 0 auto 28px auto; /* в фигме сверху 0, снизу 28 */
  }
}

.form {
  padding: 28px;
  background-color: #fff;
  border-radius: 10px;
  max-width: 560px;
  width: 100%;
  margin-top: 30px;
  box-shadow: 1px 4px 12px -2px rgba(34, 60, 80, 0.2);
}

.gender__buttons {
  display: flex;
  gap: 10px;
  margin-top: 5px;
  margin-bottom: 20px;
}

.gender-btn {
  width: 100%;
  padding: 14px 0;
  box-sizing: border-box;

  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px; /* компактно и ровно */
  font-weight: 400;
  line-height: 1.2; /* НЕ раздувает высоту */
  text-align: center;
  color: #111;

  background: none;
  border: 2px solid #e5e7eb;
  border-radius: 10px;

  cursor: pointer;
  transition: all 0.3s ease;
}

.gender-title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 15.75px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: left;
  color: oklch(0.145 0 0); /* можно заменить на #111, если oklch не хочешь */

  margin: 0 0 10.5px 0;
  box-sizing: border-box;
  /* width: 504px;  лучше не ставить жёстко, а дать блоку жить по сетке */
}

.looking-title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 15.75px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: left;
  color: oklch(0.145 0 0); /* можно заменить на #111, если oklch не хочешь */

  margin: 0 0 10.5px 0;
  box-sizing: border-box;
  /* width: 504px;  лучше не ставить жёстко, а дать блоку жить по сетке */
}

.gender-btn:hover {
  border: 2px solid #fb2c36;
  background-color: #fef2f2;
}

.gender-btn.selected {
  border: 2px solid #fb2c36;
  background-color: #fef2f2;
}

.looking__buttons {
  display: flex;
  gap: 10px;
  margin-top: 5px;
  margin-bottom: 20px;
}

.looking-btn {
  padding-block: 14px;
  width: 100%;
  border: 2px solid #e5e7eb;
  background: none;
  border-radius: 10px;

  transition: all 0.3s ease;
}

.looking-btn:hover {
  border: 2px solid #f6339a;
  background-color: #fdf2f8;
}

.looking-btn.selected {
  border: 2px solid #f6339a;
  background-color: #fdf2f8;
}

#min-val {
  color: #fb2c36;
}

#max-val {
  color: #f6339a;
}

.range-wrapper {
  width: 350px;
  margin: 40px;
  font-family: sans-serif;
}

.loading-block {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin-top: 28px;
  background-color: #fff;
  padding-inline: 54px;
  padding-block: 28px;
  max-width: 560px;
  width: 100%;
  border-radius: 15px;
  box-shadow: 1px 4px 12px -2px rgba(34, 60, 80, 0.2);
  margin-block: 144px;
}

.loading-title {
  font-size: 20px;
  font-weight: 500;
  text-align: center;
}

.loading-desc {
  font-size: 14px;
  color: #717182;
  margin-top: 7px;
  text-align: center;
}

/* From Uiverse.io by aadium */
.loader {
  display: flex;
  justify-content: center;
  align-items: center;
}

.spinner {
  width: 52px;
  height: 52px;
  position: relative;
  animation: rotation 0.75s linear infinite;
  border-radius: 100em;
}

.path {
  stroke-dasharray: 100;
  stroke-dashoffset: 20;
  stroke-linecap: round;
}

@keyframes rotation {
  to {
    transform: rotate(360deg);
  }
}

.slider {
  position: relative;
  height: 30px;
}

.slider input[type="range"] {
  position: absolute;
  width: 100%;
  pointer-events: none;
  -webkit-appearance: none;
  background: none;
}

.slider input[type="range"]::-webkit-slider-thumb {
  pointer-events: auto;
  -webkit-appearance: none;
  height: 20px;
  width: 20px;
  margin-top: 5px;
  border-radius: 50%;
  background: rgb(255, 0, 0);
  border: 4px solid #ffffff;
  cursor: pointer;
  box-shadow: 1px 4px 12px -2px rgba(34, 60, 80, 0.2);
}

.track {
  position: absolute;
  height: 6px;
  width: 100%;
  background: #f5c2d4;
  top: 50%;
  transform: translateY(-50%);
  border-radius: 3px;
}

.range {
  position: absolute;
  height: 6px;
  background: linear-gradient(90deg, #ff5c77, #ff77b4);
  top: 50%;
  transform: translateY(-50%);
  border-radius: 3px;
}

.form-btn {
  width: 100%;
  padding-block: 15px;
  margin-top: 15px;
  background: #fb2c36;
  background: linear-gradient(
    90deg,
    rgba(251, 44, 54, 1) 0%,
    rgba(246, 51, 154, 1) 100%
  );
  color: #fff;
  border: none;
  border-radius: 10px;
}

.dop {
  display: flex;
  align-items: center;
  gap: 90px;
  margin-top: 150px;
}

.dop_block {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 40px;
}

.dop-title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 26.25px;
  font-weight: 400;
  line-height: 31.5px;
  text-align: center;
  color: oklch(0.145 0 0);

  max-width: 168px;
  margin: 0 auto 7px auto;
  box-sizing: border-box;
}

.dop-desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 21px;
  text-align: center;
  color: #717182;

  max-width: 168px;
  margin: 0 auto;
  box-sizing: border-box;
}

.work {
  background: #fff;
}

.work-content {
  padding-block: 70px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.work-title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 31.5px;
  font-weight: 400;
  line-height: 35px; /* фигма */
  text-align: center;
  color: oklch(0.145 0 0); /* почти #111 */
  margin: 0 0 14px 0;
  box-sizing: border-box;
}

.work-desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: center;
  color: #717182;

  max-width: 588px;
  margin: 0 auto; /* чтобы центрировалось как в фигме */
  box-sizing: border-box;
}

.points {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 50px;
}

.point-block {
  max-width: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 5px;
}

.point-title {
  font-size: 17.5px;
}

.point-img {
  margin-bottom: 10px;
}

.point-desc {
  color: #717182;
  font-size: 14px;
}

.line {
  height: 2px;
  width: 28px;
  background-color: #ffa2a2;
  margin-top: -60px;
}

.choose {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-image: url("../assets/Section.png");
  background-size: cover;
  background-position: center;
}

.choose__title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 31.5px;
  font-weight: 400;
  line-height: 35px; /* фигма */
  text-align: center;
  margin: 40px 0 20px 0;

  /* градиент из фигмы */
  background-image: linear-gradient(
    to right,
    oklch(0.637 0.237 25.331) 0%,
    oklch(0.656 0.241 354.308) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.choost__desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: center;
  color: #717182;

  max-width: 588px;
  margin: 0 auto;

  box-sizing: border-box;
}

.cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  max-width: 1000px;
  margin-top: 56px;
  margin-bottom: 70px;
}

.card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  max-width: 318px;
  background-color: #fff;
  padding: 22px;
  box-shadow: 1px 4px 12px -2px rgba(34, 60, 80, 0.2);
  border-radius: 15px;
}

.card:hover {
  box-shadow: 1px 8px 12px -2px rgba(34, 60, 80, 0.2);
}

.card-title {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 500; /* Medium, как в фигме */
  line-height: 24.5px; /* фигма */
  text-align: center;
  color: oklch(0.145 0 0); /* почти #111 */

  margin: 14px 0 10.5px 0; /* твой top + фигмовский bottom */
  box-sizing: border-box;

  max-width: 275px; /* вместо фикс width */
  margin-left: auto;
  margin-right: auto;
}

.card-desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 21px;
  text-align: center;
  color: #717182;

  max-width: 275px;
  margin: 0 auto;
  box-sizing: border-box;
}

.love {
  background: #fb2c36;
  background: linear-gradient(
    90deg,
    rgba(251, 44, 54, 1) 0%,
    rgb(219, 18, 209) 100%
  );
}

.love-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding-block: 70px;
}

.love-title {
  color: #fff;
  font-size: 31.5px;
  margin-top: 20px;
  padding-inline: 20px;
  text-align: center;
}

.love-desc {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 400;
  line-height: 24.5px;
  text-align: center;
  color: #ffffff;
  opacity: 0.9;

  margin: 20px auto 28px auto; /* твой top + фигмовский bottom */
  padding-inline: 20px;

  max-width: 588px;
  box-sizing: border-box;
}

.love-back {
  cursor: pointer;
  padding-block: 12px;
  padding-inline: 28px;
  color: #fb2c36;
  background-color: #fff;
  border: none;
  font-weight: 500;
  border-radius: 8px;
  margin-bottom: 21px;
  margin-top: 30px;
  font-size: 12.3px;
}

.love-back:hover {
  opacity: 0.9;
}

.love-btn-desc {
  color: #fff;
  font-size: 12.3px;
  opacity: 80%;
}

.footer {
  background-color: #101828;
}

.footer-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding-block: 42px;
}

.links {
  display: flex;
  justify-content: space-between;
  max-width: 1000px;
  gap: 40px;
}

.link-block {
  display: flex;
  flex-direction: column;
}

.link-scroll {
  cursor: pointer;
}

.link-desc:hover {
  opacity: 0.8;
}

.scratch-progress {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 48px;
  height: 48px;

  border-radius: 50%;
  background: rgb(255, 0, 179);
  backdrop-filter: blur(4px);

  display: flex;
  align-items: center;
  justify-content: center;

  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;

  z-index: 50;
  pointer-events: none;
}

.radio-input {
  display: flex;
  align-items: center;
  justify-content: end;
  margin-top: 28px;
}

.radio-input input {
  appearance: none;
  width: 16px;
  height: 16px;
  background-color: #ffffff;
  border: 1px solid rgb(255, 0, 170);
  border-radius: 50%;
  transition: 0.4s ease-in-out;
}

.radio-input input:hover {
  cursor: pointer;
  box-shadow: none;
}

.radio-input .circle {
  position: relative;
  top: 0.01em;
  left: -11px;
  width: 6px;
  height: 6px;
  background-color: rgb(255, 0, 170);
  scale: 0;
  border-radius: 10px;
  transition: 0.4s ease-in-out;
}

.radio-text {
  font-size: 12.3px;
  margin-right: 10px;
  color: #717182;
}

.radio-input input:checked {
  box-shadow: none;
  border: 1px solid rgb(255, 0, 170);
}

.radio-input input:checked + .circle {
  transform: rotate(360deg);
  scale: 1;
}

#ldldlk {
  font-weight: 700;
}

#cool {
  font-weight: 600;
  font-size: 17.5px;
}

.link-title {
  display: flex;
  align-items: center;
  gap: 7px; /* как в фигме */
  box-sizing: border-box;

  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17.5px;
  font-weight: 500; /* Medium в фигме */
  line-height: 24.5px;
  color: #ffffff;

  margin: 0 0 14px 0; /* фигма */
}

.link-small {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 21px;
  color: #ffffff;
  text-align: left; /* фигма не задаёт, по умолчанию left */

  max-width: 231px;
  margin: 0 0 14px 0;
  box-sizing: border-box;
}

.link-desc {
  display: flex;
  align-items: center;
  gap: 7px; /* фигма */
  box-sizing: border-box;

  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 21px;
  color: oklch(0.707 0.022 261.325);

  max-width: 231px;
  margin: 0;
}

hr {
  width: 60%;
  opacity: 10%;
  margin-top: 30px;
  margin-bottom: 30px;
}

.copyright {
  text-align: center;
  color: #fff;
  font-size: 14px;
  opacity: 50%;
}

.found {
  display: none;
  justify-content: center;
  align-items: center;

  z-index: 1;

  max-width: 560px; /* как у .form */
  width: 100%;
  box-sizing: border-box;
  overflow: hidden; /* чтобы canvas не вылезал */
  margin-bottom: -42px;
}

.found-content {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 3;
  width: 100%;
  background-color: #fff;
  border-radius: 20px;
  padding-block: 17px;
  padding-inline: 32px;
  overflow: hidden;
}

#scratchCanvas {
  position: absolute;
  top: 0;
  width: 560px;
  height: 495px;
  cursor: crosshair;
  z-index: 22; /* выше контента */
  border-radius: 17px;
  touch-action: none;
}

.found-img {
}

.found-title {
  font-size: 21px;
  color: #f73180;
  text-align: center;
  margin-top: 14px;
}

.found-desc {
  font-size: 14px;
  color: #717182;
  margin-top: 8px;
  text-align: center;
}

.found-block {
  margin-top: 20px;
  border-radius: 10px;
  padding: 21px;
  background: #fdf2f8;
  width: 100%; /* добавлено — занимает ширину родителя */
  box-sizing: border-box; /* padding учитывается в ширине */
}

.found-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.head-text {
  font-size: 20px;
}

.head-match {
  font-size: 12px;
  padding: 4px 10px;
  background-color: #00c950;
  color: #fff;
  border-radius: 20px;
}

.found-block-text {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 14px;
  font-size: 14px;
}

.Compatibility {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 20px;
  padding: 14px;
  background-color: #fff;
  border-radius: 10px;
}

#start,
#work,
#choose,
#contact {
  text-decoration: underline;
  cursor: pointer;
}

.link-desc {
  cursor: pointer !important; /* временно, чтобы перебить все */
}

.compatibility-title {
  font-size: 12px;
  color: #717182;
}

.comp-block {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-top: 12px;
}

.found-btn {
  width: 100%;
  padding-block: 15px;
  margin-top: 15px;
  background: #fb2c36;
  background: linear-gradient(
    90deg,
    rgba(251, 44, 54, 1) 0%,
    rgba(246, 51, 154, 1) 100%
  );
  color: #fff;
  border: none;
  border-radius: 10px;
}

.found-footer {
  font-size: 14px;
  color: #717182;
  text-align: center;
  max-width: 450px;
  margin-top: 20px;
}

.comp-block-percent {
  font-size: 14px;
  color: #00a63e;
}

@media (max-width: 500px) {
  .begin {
    padding-inline: 10px;
  }

  .found {
    margin: 20px auto 0;
    margin-bottom: -30px;
  }

  .form {
    max-width: 332px;
  }

  .radio-input .circle {
    position: relative;
    top: 0.01em;
    left: -0.66em;
    width: 6px;
    height: 6px;
    background-color: rgb(255, 0, 170);
    scale: 0;
    border-radius: 10px;
    transition: 0.4s ease-in-out;
  }

  .loading-block {
    max-width: 332px;
    padding-inline: 21px;
    margin-bottom: 126px;
  }

  .dop {
    flex-direction: column;
    gap: 10px;
    margin-top: 50px;
  }

  .work-desc {
    padding-inline: 10px;
  }

  .found-content {
    padding: 20px;
    max-width: 332px;
    margin-inline: auto;
  }

  .found-title {
    margin-top: 0;
  }

  .found {
    margin-top: 0;
    margin-bottom: -32px;
  }

  .points {
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
  }

  .footer-content {
    max-width: 332px;
  }

  .line {
    display: none;
  }

  .footer-content {
    align-items: start;
  }

  .footer {
    padding-inline: 10px;
  }

  hr {
    width: 100%;
  }

  #scratchCanvas {
    width: 400px;
    height: 500px;
    top: 0;
  }

  .links {
    flex-direction: column;
  }

  .comp-block {
    width: 100%;
  }

  .comp-block-bar {
    width: 85%;
  }

  .found-footer {
    display: none;
  }
}
