/* ==========================================================================
   ProspectPoint Marketing — contact.html and the short pages that share the
   thanks layout (thanks.html, opt-out-received.html, not-sent.html).
   Loaded after styles.css. Uses the shared tokens; adds no colours or fonts.
   ========================================================================== */

/* A sentence that stays whole: it drops to its own line before it breaks. */
.sentence {
  display: inline-block;
  text-wrap: balance;
}

/* ==========================================================================
   Contact page
   ========================================================================== */

/* ---------- Form card ---------- */
.contact-card {
  box-shadow: var(--shadow);
}

/* The form sets its own rhythm, so the card's default child spacing is off. */
.contact-card > * + * {
  margin-top: 0;
}

/* Labels that wrap do so evenly, with no single word left on a line. */
.contact-card .field__label,
.contact-card legend,
.contact-card .choice span {
  text-wrap: balance;
}

/* The additional services have long names: one per row at every width. */
.choice-grid--stack {
  grid-template-columns: minmax(0, 1fr);
}

/* Status message, button and small print, set off from the questions above. */
.contact-send {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
  padding-top: var(--space-5);
  border-top: 1px solid var(--slate-200);
}

.contact-send__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
  align-items: center;
}

@media (min-width: 34em) {
  .contact-send__row {
    grid-template-columns: auto minmax(0, 1fr);
    gap: var(--space-5);
  }
}

/* The button keeps its width when its label changes to "Sending...". */
.contact-send .btn {
  min-width: 9.5rem;
}

.contact-send .form__fine {
  text-wrap: balance;
}

/* ---------- Request sent (replaces the form) ---------- */
/* The page scrolls to this block. The margin keeps the top edge of the card
   around it clear of the header. */
.contact-done {
  scroll-margin-top: var(--space-6);
}

.contact-done h2 {
  font-size: 1.5rem;
}

.contact-done a {
  overflow-wrap: anywhere;
}

/* ---------- Side panel ---------- */
.contact-aside {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-5);
}

.contact-aside h2 {
  font-size: var(--fs-h3);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.contact-aside p,
.contact-aside li {
  font-size: var(--fs-small);
  color: var(--slate-600);
}

.contact-aside a {
  overflow-wrap: anywhere;
}

/* For people who received a campaign email, not for people asking for a proposal. */
.contact-aside__note {
  background: transparent;
}

/* Stacked under the form on tablets: two columns, the steps on the right.
   It starts at 45em, the narrowest width at which the email address fits its card. */
@media (min-width: 45em) and (max-width: 61.99em) {
  .contact-aside {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-aside__steps {
    grid-column: 2;
    grid-row: 1 / span 2;
  }
}

/* Beside the form on wide screens: it stays in view while the form scrolls,
   on any screen tall enough to show all of it under the header. */
@media (min-width: 62em) and (min-height: 45em) {
  .contact-aside {
    position: sticky;
    top: calc(var(--header-h) + var(--space-5));
  }
}

/* ==========================================================================
   Thanks page
   ========================================================================== */

/* A short page: on a tall screen the footer stays at the bottom and the band
   fills the space above it, with the message in the middle. */
.page-thanks {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.page-thanks main,
.page-thanks .page-header,
.page-thanks .page-header > .container {
  display: flex;
  flex: 1 0 auto;
  flex-direction: column;
}

.page-thanks .page-header > .container {
  justify-content: center;
}

/* The email address in the lead sits on navy. */
.page-thanks .lead a {
  color: var(--cyan-200);
  overflow-wrap: anywhere;
}

.page-thanks .lead a:hover {
  color: var(--white);
}

/* On the narrowest phones a line is shorter than the address on the "not
   sent" page. There it wraps after the @ within the sentence, instead of
   leaving "info@" on a line of its own. */
@media (max-width: 20.99em) {
  .page-thanks .lead a.sentence {
    display: inline;
  }
}

/* On a phone the two buttons take the full width, one under the other. */
@media (max-width: 33.99em) {
  .page-thanks .page-header__action .btn {
    width: 100%;
  }
}
