/* Contact forms (quotation and documentation requests).
   Scoped under .cf-* so nothing here can leak into the rest of the site.
   Type scale and fonts are inherited from the site stylesheet. */

.cf {
  --cf-violet: #7C4B8C;
  --cf-violet-dark: #663e73;
  --cf-tint: #F4F1F7;
  --cf-rule: rgba(0, 0, 0, 0.14);
  --cf-quiet: rgba(0, 0, 0, 0.6);
  --cf-error: #B3261E;
  --cf-radius: 4px;
  max-width: 72rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 5rem;
  box-sizing: border-box;
  color: #111;
}

.cf *,
.cf *::before,
.cf *::after {
  box-sizing: border-box;
}

.cf__head {
  margin: 0 0 2.5rem;
  max-width: 44rem;
}

.cf__eyebrow {
  margin: 0 0 0.25rem;
  color: var(--cf-violet);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.85rem;
  font-weight: 700;
}

.cf__head h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1.15;
}

.cf__lede {
  margin: 0;
  font-size: 1.15rem;
}

/* minmax(0, 1fr): a select is as wide as its longest option otherwise */
.cf__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2.5rem;
}

@media (min-width: 60rem) {
  .cf__layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    gap: 3.5rem;
    align-items: start;
  }
  .cf-aside {
    position: sticky;
    top: calc(var(--header-h, 6rem) + 1.5rem);
  }
}

/* Aside: product, next steps, direct contacts. Last on small screens. */

.cf-aside {
  order: 2;
  padding: 1.5rem;
  background: var(--cf-tint);
  border-radius: var(--cf-radius);
}

@media (min-width: 60rem) {
  .cf-aside { order: 0; }
}

.cf-aside__image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 0 1rem;
  border-radius: var(--cf-radius);
}

.cf-aside__summary {
  margin: 0 0 1.5rem;
}

.cf-aside h2 {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
}

.cf-steps {
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
  counter-reset: cf-step;
}

.cf-steps li {
  position: relative;
  margin: 0 0 0.75rem;
  padding-left: 2.25rem;
  counter-increment: cf-step;
}

.cf-steps li::before {
  content: counter(cf-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: var(--cf-violet);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.6rem;
  text-align: center;
}

.cf-aside__direct {
  margin: 0;
  padding-top: 1rem;
  border-top: 1px solid var(--cf-rule);
  line-height: 1.8;
}

/* Form */

.cf-form__legend-note {
  margin: 0 0 1rem;
  color: var(--cf-quiet);
  font-size: 0.9rem;
}

.cf-req {
  color: var(--cf-violet);
  font-weight: 700;
}

.cf-alert {
  margin: 0 0 1.5rem;
  padding: 0.85rem 1rem;
  border-left: 4px solid var(--cf-error);
  background: #FCEEEE;
  color: var(--cf-error);
  font-weight: 700;
}

.cf-fieldset {
  margin: 0 0 2rem;
  padding: 0;
  border: 0;
  min-width: 0;
}

.cf-fieldset legend {
  width: 100%;
  margin: 0 0 1rem;
  padding: 0 0 0.5rem;
  border-bottom: 2px solid var(--cf-violet);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--cf-violet-dark);
}

.cf-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.1rem 1.25rem;
}

@media (min-width: 36rem) {
  .cf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cf-field--wide { grid-column: 1 / -1; }
}

.cf-field label {
  display: block;
  margin: 0 0 0.35rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: #333;
}

.cf-field input,
.cf-field select,
.cf-field textarea {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 2.75rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid #B9B4C0;
  border-radius: var(--cf-radius);
  background: #fff;
  font: inherit;
  color: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.cf-field textarea {
  min-height: 9rem;
  resize: vertical;
  line-height: 1.5;
}

.cf-field input:hover,
.cf-field select:hover,
.cf-field textarea:hover {
  border-color: #8C8494;
}

.cf-field input:focus,
.cf-field select:focus,
.cf-field textarea:focus {
  outline: none;
  border-color: var(--cf-violet);
  box-shadow: 0 0 0 3px rgba(124, 75, 140, 0.25);
}

/* Products of interest: checkboxes drawn as toggle chips */

.cf-field__label {
  margin: 0 0 0.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: #333;
}

.cf-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cf-field .cf-choice {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.5rem 0.9rem;
  border: 1px solid #B9B4C0;
  border-radius: 999px;
  background: #fff;
  font-weight: 400;
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}

.cf-field .cf-choice input {
  display: inline-block;
  width: 1.05rem;
  height: 1.05rem;
  min-height: 0;
  margin: 0;
  padding: 0;
  accent-color: var(--cf-violet);
}

.cf-field .cf-choice:hover {
  border-color: var(--cf-violet);
}

.cf-field .cf-choice:has(input:checked) {
  border-color: var(--cf-violet);
  background: var(--cf-tint);
  color: var(--cf-violet-dark);
  font-weight: 700;
}

.cf-field .cf-choice:has(input:focus-visible) {
  box-shadow: 0 0 0 3px rgba(124, 75, 140, 0.25);
}

.cf-help {
  margin: 0.3rem 0 0;
  color: var(--cf-quiet);
  font-size: 0.85rem;
}

.cf-error {
  margin: 0.3rem 0 0;
  color: var(--cf-error);
  font-size: 0.9rem;
  font-weight: 700;
}

.cf-field--error input,
.cf-field--error select,
.cf-field--error textarea {
  border-color: var(--cf-error);
}

.cf-consent {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.25rem 0.75rem;
  align-items: start;
  margin: 0 0 1.75rem;
  padding: 1rem;
  border: 1px solid var(--cf-rule);
  border-radius: var(--cf-radius);
}

.cf-consent input {
  width: 1.2rem;
  height: 1.2rem;
  margin: 0.15rem 0 0;
  accent-color: var(--cf-violet);
}

.cf-consent .cf-error {
  grid-column: 2;
}

.cf-consent.cf-field--error {
  border-color: var(--cf-error);
}

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

.cf-submit,
.cf-button {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  border: 2px solid var(--cf-violet);
  border-radius: var(--cf-radius);
  background: var(--cf-violet);
  color: #fff;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}

.cf-submit {
  width: 100%;
  font-size: 1.05rem;
}

@media (min-width: 36rem) {
  .cf-submit { width: auto; min-width: 16rem; }
}

.cf-submit:hover,
.cf-button:hover {
  background: var(--cf-violet-dark);
  border-color: var(--cf-violet-dark);
  color: #fff;
}

.cf-submit:focus-visible,
.cf-button:focus-visible {
  outline: 3px solid rgba(124, 75, 140, 0.4);
  outline-offset: 2px;
}

.cf-button--quiet {
  background: transparent;
  color: var(--cf-violet);
}

.cf-button--quiet:hover {
  background: var(--cf-tint);
  color: var(--cf-violet-dark);
}

/* Thank-you page */

.cf--thanks {
  max-width: 44rem;
  text-align: center;
}

.cf--thanks .cf__head {
  margin-left: auto;
  margin-right: auto;
}

.cf-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  margin: 1rem 0 1.25rem;
  border-radius: 50%;
  background: var(--cf-violet);
  color: #fff;
  font-size: 1.75rem;
}

.cf-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin: 0;
}
