/* Contact form — минималистичный стиль (CellPoint-like) */
.rb-section.contact-terminal-section {
  position: relative;
  padding: 5rem 0 0;
  background: #fff;
  color: #1a1a1a;
  overflow: hidden;
}

.contact-form-shell {
  position: relative;
  z-index: 2;
}

.contact-form-side-panel {
  position: absolute;
  right: clamp(-14rem, calc((100vw - min(80rem, 100vw - 3rem)) / 2 - 16rem), -2rem);
  top: auto;
  bottom: 0;
  transform: none;
  z-index: 1;
  width: min(1180px, 82vw);
  max-width: 1180px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  pointer-events: none;
}

.contact-form-visual--planet {
  position: relative;
  right: auto;
  bottom: auto;
  width: 100%;
  max-width: none;
  line-height: 0;
  align-self: center;
  transform: none;
}

.contact-form-visual--planet img {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(88vh, 900px);
  object-fit: contain;
  object-position: center bottom;
}

.contact-form-visual--floor {
  position: relative;
  right: auto;
  bottom: auto;
  width: 100%;
  max-width: none;
  line-height: 0;
  align-self: flex-end;
  transform: translateX(2.5rem);
}

.contact-form-visual--floor img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 680px;
  object-fit: contain;
  object-position: right bottom;
}

.contact-form-layout {
  display: grid;
  gap: 2.5rem;
  align-items: start;
  position: relative;
  z-index: 2;
  padding-bottom: 5rem;
}

@media (min-width: 992px) {
  .contact-form-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    align-items: start;
    padding-bottom: 7rem;
    min-height: 560px;
    max-width: 720px;
  }
}

.contact-form-main {
  min-width: 0;
  max-width: 720px;
}

.contact-form-tg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.9rem 1.6rem;
  border-radius: 12px;
  background: #2d9cdb;
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 14px rgba(45, 156, 219, 0.35);
  align-self: flex-start;
}

.contact-form-tg-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(45, 156, 219, 0.45);
  color: #fff;
}

.contact-form-tg-gif {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
}

.contact-form-intro {
  margin-bottom: 2.5rem;
}

.contact-form-title {
  margin: 0 0 1.25rem;
  font-size: clamp(1.75rem, 3.2vw, 2.25rem);
  font-weight: 400;
  line-height: 1.25;
  color: #1a1a1a;
  letter-spacing: -0.02em;
}

.contact-form-title strong {
  font-weight: 700;
}

.contact-form-desc {
  margin: 0 0 1.5rem;
  max-width: 52ch;
  font-size: 1rem;
  line-height: 1.55;
  color: rgba(26, 26, 26, 0.72);
}

.contact-form-lead {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.4;
  color: #1a1a1a;
}

.contact-form-message {
  min-height: 0;
  margin: 0 0 1rem;
  font-size: 0.875rem;
  line-height: 1.4;
  color: rgba(26, 26, 26, 0.75);
}

.contact-form-message.is-success {
  color: #1a7f4b;
}

.contact-form-message.is-error {
  color: #b42318;
}

.contact-terminal-form .ct-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem 2.5rem;
}

@media (min-width: 640px) {
  .contact-terminal-form .ct-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.ct-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.ct-field--full {
  margin-top: 2rem;
}

.ct-label {
  font-size: 0.8125rem;
  font-weight: 400;
  line-height: 1.3;
  color: rgba(26, 26, 26, 0.55);
}

.ct-req {
  color: #c41e3a;
  margin-left: 2px;
}

.ct-input,
.ct-textarea {
  width: 100%;
  border: 0;
  border-bottom: 1px solid rgba(26, 26, 26, 0.22);
  border-radius: 0;
  background: transparent;
  color: #1a1a1a;
  padding: 0.5rem 0 0.65rem;
  outline: none;
  font-size: 1rem;
  line-height: 1.4;
  transition: border-color 0.2s ease;
  box-shadow: none;
}

.ct-textarea {
  resize: vertical;
  min-height: 100px;
  padding-top: 0.35rem;
}

.ct-input::placeholder,
.ct-textarea::placeholder {
  color: transparent;
}

.ct-input:focus,
.ct-textarea:focus {
  border-bottom-color: #1a1a1a;
  box-shadow: none;
}

.ct-input.is-invalid,
.ct-textarea.is-invalid {
  border-bottom-color: #c41e3a;
  box-shadow: none;
}

.ct-footnote {
  margin: 2rem 0 1.25rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: rgba(26, 26, 26, 0.45);
  max-width: 52ch;
}

.contact-form-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.85rem;
}

.contact-form-actions .contact-form-tg-btn {
  white-space: nowrap;
}

.ct-submit {
  display: inline-block;
  margin: 0;
  padding: 12px 24px;
  border: 0;
  border-radius: 0.375rem;
  cursor: pointer;
  background-color: #186aff;
  color: #fff;
  font: 14px Inter, sans-serif;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: 0;
  width: auto;
  min-width: 140px;
  text-align: center;
  transition: opacity 0.2s ease;
}

.ct-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.ct-submit:hover:not(:disabled) {
  opacity: 0.92;
}

.ct-submit:active:not(:disabled) {
  opacity: 0.88;
}

.ct-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

@media (max-width: 991px) {
  .contact-form-side-panel {
    position: relative;
    right: auto;
    top: auto;
    bottom: auto;
    transform: none;
    width: 100%;
    max-width: 760px;
    margin: 2.5rem auto 0;
    pointer-events: auto;
  }

  .contact-form-layout {
    padding-bottom: 0;
  }

  .contact-form-visual--planet img {
    max-height: 420px;
  }

  .contact-form-visual--floor {
    transform: translateX(1rem);
  }

  .contact-form-visual--floor img {
    max-height: 420px;
  }

  .rb-section.contact-terminal-section {
    padding-bottom: 3rem;
  }
}

@media (max-width: 639px) {
  .rb-section.contact-terminal-section {
    padding: 3.5rem 0 2.5rem;
  }

  .contact-form-intro {
    margin-bottom: 2rem;
  }

  .contact-terminal-form .ct-grid {
    gap: 1.75rem;
  }

  .ct-field--full {
    margin-top: 1.75rem;
  }
}
