.calc {
  --calc-navy: #04182d;
  --calc-orange: #f25301;
  --calc-muted: #5d6b7a;
  --calc-line: #e4e9ef;
  --calc-error: #c5362b;

  position: relative;
  max-width: 1920px;
  margin-inline: auto;
  background: #f3f6f8;
  color: var(--calc-navy);
  font-family: Manrope, sans-serif;
}

.calc__bg {
  position: absolute;
  inset: 0;
  background: url("../../img/calc/bg-rasschet-proekta.webp") center top / cover no-repeat;
  pointer-events: none;
}

.calc__inner {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(840px, 1fr) minmax(280px, 560px);
  align-items: start;
  gap: 40px;
  padding: 48px 52px 72px;
}

.calc__intro {
  min-width: 0;
  padding-top: 8px;
}

.calc__eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 18px;
}

.calc__eyebrow-num {
  color: var(--calc-orange);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1;
}

.calc__eyebrow-line {
  flex: none;
  width: 36px;
  height: 2px;
  background: var(--calc-orange);
}

.calc__eyebrow-label {
  color: #8b95a1;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.16em;
  line-height: 1;
  text-transform: uppercase;
}

.calc__title {
  margin: 0;
  color: var(--calc-navy);
  font-size: 60px;
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.02;
  white-space: nowrap;
}

.calc__lead {
  max-width: 640px;
  margin: 20px 0 0;
  color: #2c3a48;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.45;
}

.calc__benefits {
  display: grid;
  grid-template-columns: repeat(4, max-content);
  justify-content: space-between;
  gap: 0;
  margin: 36px 0 0;
  max-width: 860px;
}

.calc__benefit {
  min-width: 0;
  margin: 0;
  padding: 0 10px 0 12px;
  border-left: 1px solid rgba(4, 24, 45, 0.14);
}

.calc__benefit:first-child {
  padding-left: 0;
  border-left: 0;
}

.calc__benefit img {
  display: block;
  width: 36px;
  height: 36px;
  object-fit: contain;
  object-position: left center;
}

.calc__benefit p {
  margin: 10px 0 0;
  color: var(--calc-navy);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.calc__form {
  min-width: 0;
  margin: 0;
  padding: 28px 28px 22px;
  border-radius: 18px;
  background: #fff;
}

.calc__form-title {
  margin: 0 0 18px;
  color: var(--calc-navy);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.calc__field {
  position: relative;
  margin: 0 0 14px;
}

.calc__label {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.calc__field-icon {
  position: absolute;
  top: 16px;
  left: 16px;
  width: 20px;
  height: 20px;
  object-fit: contain;
  pointer-events: none;
}

.calc__field input {
  box-sizing: border-box;
  width: 100%;
  height: 52px;
  margin: 0;
  padding: 0 16px 0 48px;
  border: 1px solid var(--calc-line);
  border-radius: 12px;
  background: #fff;
  color: var(--calc-navy);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
}

.calc__field input::placeholder {
  color: #9aa6b2;
}

.calc__field input:focus {
  border-color: #b7c3d0;
  outline: 2px solid rgba(242, 83, 1, 0.28);
  outline-offset: 1px;
}

.calc__field input[aria-invalid="true"] {
  border-color: var(--calc-error);
}

.calc__error {
  min-height: 0;
  margin: 0;
  color: var(--calc-error);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.calc__error:empty {
  display: none;
}

.calc__field .calc__error {
  margin-top: 4px;
}

.calc__files-title {
  margin: 16px 0 10px;
  color: var(--calc-navy);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
}

.calc__drop {
  position: relative;
}

.calc__file {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.calc__drop-label {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 96px;
  margin: 0;
  padding: 14px 16px;
  border: 1.5px dashed #d5dde6;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
}

.calc__drop.is-over .calc__drop-label {
  border-color: var(--calc-orange);
  background: rgba(242, 83, 1, 0.04);
}

.calc__clip {
  display: grid;
  flex: none;
  place-items: center;
  width: 67px;
  height: 67px;
  border-radius: 50%;
  background: #f2f4f7;
}

.calc__clip img {
  width: 67px;
  height: 67px;
  object-fit: contain;
}

.calc__drop-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.calc__drop-title {
  color: var(--calc-navy);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.25;
}

.calc__drop-note {
  color: #8b95a1;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
}

.calc__file-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 8px 0 0;
}

.calc__file-list:empty {
  display: none;
}

.calc__file-item {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--calc-navy);
  font-size: 13px;
  font-weight: 600;
}

.calc__file-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calc__file-remove {
  flex: none;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--calc-muted);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.calc__file-remove:hover {
  color: var(--calc-error);
}

.calc__consent-wrap {
  margin-top: 14px;
}

.calc__consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--calc-navy);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  cursor: pointer;
}

.calc__check {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  border: 1.5px solid #c5ced8;
  border-radius: 4px;
  background: #fff;
  appearance: none;
  cursor: pointer;
}

.calc__check:checked {
  border-color: var(--calc-orange);
  background: var(--calc-orange) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10'%3E%3Cpath d='M1 5.2 4.2 8.4 11 1.4' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px 10px no-repeat;
}

.calc__check:focus-visible {
  outline: 2px solid var(--calc-orange);
  outline-offset: 2px;
}

.calc__policy {
  color: var(--calc-navy);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.calc__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 100%;
  height: 54px;
  margin-top: 16px;
  padding: 0 48px;
  border: 0;
  border-radius: 12px;
  background: var(--calc-orange);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.calc__submit svg {
  position: absolute;
  top: 50%;
  right: 18px;
  width: 22px;
  height: 12px;
  transform: translateY(-50%);
}

.calc__submit:hover {
  background: #ff6a1f;
}

.calc__submit:disabled {
  cursor: default;
  opacity: 0.72;
}

.calc__status {
  margin: 10px 0 0;
  color: var(--calc-navy);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
}

.calc__status[hidden] {
  display: none;
}

.calc__hint {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0 0;
  color: var(--calc-navy);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
}

.calc__hint svg {
  flex: none;
  width: 22px;
  height: 22px;
  color: #8b95a1;
}

@media (max-width: 1279px) {
  .calc__inner {
    grid-template-columns: 1fr;
    padding: 32px 20px 40px;
  }

  .calc__title {
    font-size: 40px;
    white-space: normal;
  }

  .calc__benefits {
    grid-template-columns: 1fr 1fr;
    gap: 16px 0;
    max-width: none;
  }
}

@media (max-width: 767px) {
  .calc__title {
    font-size: 32px;
  }

  .calc__benefits {
    grid-template-columns: 1fr;
  }
}

.calc--animate:not(.is-inview) .calc__eyebrow,
.calc--animate:not(.is-inview) .calc__title,
.calc--animate:not(.is-inview) .calc__lead,
.calc--animate:not(.is-inview) .calc__benefit,
.calc--animate:not(.is-inview) .calc__form {
  opacity: 0;
  transform: translateY(40px);
}

.calc--animate.is-inview .calc__eyebrow,
.calc--animate.is-inview .calc__title,
.calc--animate.is-inview .calc__lead,
.calc--animate.is-inview .calc__benefit,
.calc--animate.is-inview .calc__form {
  animation: services-rise 0.8s ease both;
}

.calc--animate.is-inview .calc__title {
  animation-delay: 0.08s;
}

.calc--animate.is-inview .calc__lead {
  animation-delay: 0.16s;
}

.calc--animate.is-inview .calc__benefit:nth-child(1) { animation-delay: 0.24s; }
.calc--animate.is-inview .calc__benefit:nth-child(2) { animation-delay: 0.32s; }
.calc--animate.is-inview .calc__benefit:nth-child(3) { animation-delay: 0.4s; }
.calc--animate.is-inview .calc__benefit:nth-child(4) { animation-delay: 0.48s; }

.calc--animate.is-inview .calc__form {
  animation-delay: 0.56s;
}

.calc--animate.is-inview .calc__benefit.is-shown,
.calc--animate.is-inview .calc__form.is-shown {
  animation: none;
  opacity: 1;
  transform: none;
}
