/* Contato (/contato/). Loaded only on that page. One main action: the form. */
.ct {
  padding-top: var(--page-top);
  padding-bottom: clamp(56px, 7vw, 104px);
  background: var(--paper);
  --ct-field-border: #77758f;
  --ct-error: #b3261e;
}

/* Focus ring with enough contrast on the paper and white surfaces */
.ct :focus-visible {
  outline: 3px solid var(--indigo);
  outline-offset: 3px;
}

.ct-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}

.ct-head .section-index {
  margin-bottom: var(--eyebrow-gap);
}

.ct-audience {
  max-width: 520px;
  margin: 12px 0 0;
  color: var(--ink);
  font-size: var(--fs-base);
  font-weight: 650;
  line-height: 1.5;
}

/* Form card */
.ct-form-card {
  padding: clamp(20px, 3vw, 36px);
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--white);
}

.ct-form {
  display: grid;
  gap: 16px;
}

.ct-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.ct-field label,
.ct-label {
  display: block;
  margin: 0 0 6px;
  color: var(--ink);
  font-size: var(--fs-sm);
  font-weight: 650;
}

.ct-label {
  margin-bottom: 12px;
  font-size: var(--fs-xs);
  font-weight: 750;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.ct-optional {
  color: var(--muted);
  font-weight: 500;
}

.ct-field input[type="text"],
.ct-field input[type="email"],
.ct-field input[type="tel"],
.ct-field select,
.ct-field textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 11px 14px;
  border: 1px solid var(--ct-field-border);
  border-radius: 2px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-size: var(--fs-base);
  line-height: 1.4;
}

.ct-field textarea {
  min-height: 92px;
  resize: vertical;
}

.ct-field select {
  padding-right: 40px;
  appearance: none;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f1646' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right 12px center / 18px no-repeat;
}

.ct-field input:focus-visible,
.ct-field select:focus-visible,
.ct-field textarea:focus-visible {
  border-color: var(--blue-dark);
  outline-offset: 1px;
}

.ct-field [aria-invalid="true"] {
  border-color: var(--ct-error);
  box-shadow: inset 0 0 0 1px var(--ct-error);
}

.ct-error {
  margin: 6px 0 0;
  color: var(--ct-error);
  font-size: var(--fs-sm);
  font-weight: 600;
  line-height: 1.4;
}

.ct-error:empty {
  display: none;
}

.ct-error--form {
  margin: 0;
  padding: 12px 14px;
  border-left: 3px solid var(--ct-error);
  background: #fdf1f0;
}

/* Consent */
.ct-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.ct-check input {
  flex: none;
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--blue-dark);
}

.ct-check label {
  margin: 0;
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 500;
  line-height: 1.5;
}

.ct-check a {
  color: var(--blue-dark);
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Honeypot: out of sight, still in the DOM for bots */
.ct-trap {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Submit */
.ct-submit {
  width: 100%;
  min-height: 56px;
  margin-top: 4px;
  cursor: pointer;
  font-size: var(--fs-base);
}

.ct-submit[disabled] {
  cursor: progress;
  border-color: var(--blue-pale);
  background: var(--blue-pale);
  color: var(--indigo);
  transform: none;
}

.ct-submit__loading::after {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-left: 10px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  vertical-align: -2px;
  animation: ct-spin 0.8s linear infinite;
}

.ct-submit[disabled] svg {
  display: none;
}

@keyframes ct-spin {
  to {
    transform: rotate(360deg);
  }
}

/* Success replaces the form */
.ct-success {
  padding: clamp(8px, 2vw, 20px) 0;
}

.ct-success:focus {
  outline: none;
}

.ct-success__title {
  margin: 0 0 12px;
  color: var(--blue-dark);
  font-size: var(--fs-h2);
  font-weight: 450;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.ct-success p {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: var(--fs-lg);
  line-height: 1.6;
}

.ct-success__next {
  color: var(--muted);
}

/* After the form: what happens next, then direct channels */
.ct-expect ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: var(--fs-base);
  line-height: 1.6;
}

.ct-expect li + li {
  margin-top: 4px;
}

.ct-direct {
  padding-top: 24px;
  border-top: 1px solid var(--line-strong);
}

.ct-direct__title {
  margin: 0 0 16px;
  color: var(--ink);
  font-size: var(--fs-xl);
  font-weight: 500;
  letter-spacing: -0.02em;
}

.ct-whatsapp {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-height: 48px;
  padding: 8px 22px;
  border-radius: 2px;
  background: var(--indigo);
  color: var(--white);
  transition: background 0.25s ease;
}

.ct-whatsapp:hover {
  background: var(--blue-dark);
}

.ct-whatsapp__label {
  font-size: var(--fs-sm);
  font-weight: 700;
}

.ct-whatsapp__number {
  font-size: var(--fs-sm);
  opacity: 0.9;
}

.ct-direct__list {
  display: grid;
  gap: 8px;
  margin: 18px 0 0;
  padding: 0;
  color: var(--muted);
  font-size: var(--fs-base);
  list-style: none;
}

.ct-direct__list span {
  display: inline-block;
  min-width: 68px;
  color: var(--ink);
  font-weight: 650;
}

.ct-link {
  padding: 8px 0;
  color: var(--blue-dark);
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.ct-link:hover {
  color: var(--indigo);
}

/* Discreet blocks: support and address */
.ct-more {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
  margin-top: clamp(40px, 5vw, 72px);
  padding-top: 32px;
  border-top: 1px solid var(--line-strong);
}

.ct-more p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.6;
}

.ct-more strong {
  color: var(--ink);
}

@media (min-width: 841px) {
  .ct-layout {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    grid-template-areas:
      "head form"
      "expect form"
      "direct form";
    grid-template-rows: auto auto 1fr;
    column-gap: clamp(40px, 6vw, 96px);
    row-gap: 28px;
    align-items: start;
  }

  .ct-head {
    grid-area: head;
  }

  .ct-form-card {
    grid-area: form;
  }

  .ct-expect {
    grid-area: expect;
  }

  .ct-direct {
    grid-area: direct;
  }

  .ct-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ct-more {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  .ct {
    padding-top: var(--page-top);
  }

  .ct-whatsapp {
    width: 100%;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ct-submit__loading::after {
    animation-duration: 2s;
  }
}
