/* ==========================================================================
   LORQEN — enquiry forms (contact, corporate, partner pages)
   Shared by every theme: everything reads the theme's own tokens
   (--line, --accent, --text …) with a fallback, so a theme that has not
   styled these pieces still gets a clean, legible control.
   ========================================================================== */

/* --- Required-field messages ------------------------------------------- */
.field__error[hidden] { display: none !important; }
.field__error {
  margin: 0.15rem 0 0;
  font-family: var(--font-ui, inherit);
  font-size: var(--fs-xs, 0.8125rem);
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  line-height: 1.45;
  color: #B3261E;
}
.surface-dark .field__error,
.surface-charcoal .field__error,
.cta-band .field__error { color: #FF9B8F; }

.field.has-error .field__control,
.field.has-error .msel__btn {
  border-color: #C0453A !important;
  box-shadow: 0 0 0 3px rgba(192, 69, 58, 0.16) !important;
}
.surface-dark .field.has-error .field__control,
.surface-charcoal .field.has-error .field__control { border-color: #E0766B !important; }

.form__status[hidden] { display: none !important; }
.form__status--error {
  margin: 0 0 var(--sp-5, 1.5rem);
  padding: 0.8rem 1rem;
  max-width: none;
  border-radius: var(--radius, 6px);
  border: 1px solid rgba(192, 69, 58, 0.45);
  background: rgba(192, 69, 58, 0.08);
  color: #B3261E;
  font-family: var(--font-ui, inherit);
  font-size: var(--fs-sm, 0.9375rem);
  font-weight: 600;
}
.surface-dark .form__status--error,
.surface-charcoal .form__status--error { color: #FFB4AB; border-color: rgba(224, 118, 107, 0.5); background: rgba(224, 118, 107, 0.1); }

/* The hint sits between the label and the error; keep them close. */
.field > .field__hint + .field__error { margin-top: 0; }

/* "(optional)" after a label: quieter than the label itself. */
.field__opt {
  font-weight: 400;
  letter-spacing: 0.02em;
  text-transform: none;
  opacity: 0.8;
}

/* --- Multi-select dropdown --------------------------------------------- */
.msel { position: relative; }
.msel__btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  text-align: left;
  cursor: pointer;
}
.msel__value { display: flex; flex-wrap: wrap; gap: 0.4rem; min-width: 0; flex: 1 1 auto; }
.msel__placeholder { color: var(--text-dim, #8a8578); }
.msel__chip {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 0.22rem 0.65rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent, #C9A227) 45%, transparent);
  background: color-mix(in srgb, var(--accent, #C9A227) 12%, transparent);
  color: var(--text, inherit);
  font-family: var(--font-ui, inherit);
  font-size: var(--fs-xs, 0.8125rem);
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.msel__chip--more { background: transparent; }
.msel__caret {
  flex: 0 0 auto;
  width: 0.55rem;
  height: 0.55rem;
  margin-right: 0.15rem;
  border-right: 1.5px solid var(--accent, #C9A227);
  border-bottom: 1.5px solid var(--accent, #C9A227);
  transform: translateY(-25%) rotate(45deg);
  transition: transform 0.18s ease;
}
.msel.is-open .msel__caret { transform: translateY(15%) rotate(-135deg); }
.msel.is-open .msel__btn { border-color: var(--accent, #C9A227); box-shadow: 0 0 0 3px var(--focus-ring, rgba(201, 162, 39, 0.18)); }

.msel__panel {
  display: none;
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  margin: 0;
  padding: 0.4rem;
  list-style: none;
  max-height: 18rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--bg, #fff);
  border: 1px solid var(--line-accent, var(--line, #ddd));
  border-radius: calc(var(--radius, 6px) + 2px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}
.msel.is-open .msel__panel { display: block; }
.msel__panel li { margin: 0; }
.msel__opt {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.65rem;
  border-radius: var(--radius, 6px);
  cursor: pointer;
  font-family: var(--font-ui, inherit);
  font-size: var(--fs-sm, 0.9375rem);
  line-height: 1.35;
  color: var(--text, inherit);
  text-transform: none;
  letter-spacing: 0;
}
.msel__opt:hover,
.msel__opt:focus-within { background: color-mix(in srgb, var(--accent, #C9A227) 12%, transparent); }
.msel__opt input {
  flex: 0 0 auto;
  width: 1.05rem;
  height: 1.05rem;
  margin: 0;
  accent-color: var(--accent, #C9A227);
}
.msel__opt input:checked + span { color: var(--text, inherit); font-weight: 600; }

/* No JavaScript: the tick boxes are simply listed under the label. */
html.no-js .msel__btn { display: none; }
html.no-js .msel__panel { display: block; position: static; box-shadow: none; max-height: none; }

/* --- Contact-page router ------------------------------------------------ */
.enq { position: relative; }
.enq > [hidden] { display: none !important; }
.enq__router .field__hint { margin: 0 0 0.25rem; }
.enq__router .form__foot { margin-top: var(--sp-6, 1.75rem); }
.enq__back {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0 0 var(--sp-5, 1.25rem);
  font-family: var(--font-ui, inherit);
  font-size: var(--fs-xs, 0.8125rem);
  color: var(--text-muted, inherit);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: color-mix(in srgb, currentColor 40%, transparent);
}
.enq__back:hover { color: var(--accent, inherit); }
.enq__redirect-kicker { margin: 0 0 var(--sp-3, 0.75rem); }
.enq__redirect .form__intro { max-width: 46ch; }
.enq__redirect .form__foot { margin-top: var(--sp-6, 1.75rem); }
