/* Kaizen enquiry form (shared/enquiry-form.js). Uses each page's theme tokens,
   with fallbacks so it also works on a page that doesn't define them. */
.kz-eq {
  --eq-accent: var(--accent, #38b6ff);
  --eq-text: var(--white, #ffffff);
  --eq-muted: var(--grey, rgba(255,255,255,0.5));
  --eq-border: var(--border, rgba(255,255,255,0.07));
  --eq-field: rgba(255,255,255,0.03);
  --eq-field-border: rgba(255,255,255,0.12);
  --eq-error: #ff6b6b;
  display: flex; flex-direction: column; gap: 26px;
  font-family: inherit; color: var(--eq-text); text-align: left;
}
[data-theme="light"] .kz-eq {
  --eq-field: #ffffff;
  --eq-field-border: rgba(0,0,0,0.16);
  --eq-error: #c62828;
}

/* Steps */
.kz-eq-progress { display: flex; gap: 6px; }
.kz-eq-progress-bar { flex: 1; height: 4px; border-radius: 4px; background: var(--eq-field-border); transition: background 0.3s; }
.kz-eq-progress-bar.is-on { background: var(--eq-accent); }
.kz-eq-step { display: flex; flex-direction: column; gap: 26px; }
.kz-eq-step[hidden] { display: none; }
.kz-eq-step-h { font-size: 1.45rem; font-weight: 900; letter-spacing: -0.03em; line-height: 1.2; margin: 0; outline: none; }
.kz-eq-step-n { display: block; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--eq-muted); margin-bottom: 6px; }
.kz-eq-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.kz-eq-back {
  font: inherit; font-weight: 600; font-size: 0.9rem; cursor: pointer;
  color: var(--eq-text); background: transparent;
  border: 1px solid var(--eq-field-border); border-radius: 100px; padding: 14px 24px;
  transition: border-color 0.2s, background 0.2s;
}
.kz-eq-back:hover { border-color: var(--eq-accent); }
.kz-eq-back:focus-visible { outline: 2px solid var(--eq-accent); outline-offset: 3px; }

.kz-eq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 16px; }
.kz-eq-field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.kz-eq-set { border: 0; padding: 0; margin: 0; min-width: 0; }

.kz-eq-label { display: block; font-size: 0.86rem; font-weight: 600; color: var(--eq-text); padding: 0; }
.kz-eq-set > .kz-eq-label { margin-bottom: 14px; }
.kz-eq-hint { font-weight: 400; color: var(--eq-muted); font-size: 0.8rem; margin-left: 4px; }

.kz-eq input[type="text"], .kz-eq input[type="email"], .kz-eq input[type="tel"], .kz-eq textarea {
  width: 100%; font: inherit; font-size: 16px; /* 16px stops iOS zooming on focus */
  color: var(--eq-text); background: var(--eq-field);
  border: 1px solid var(--eq-field-border); border-radius: 12px;
  padding: 13px 15px; transition: border-color 0.2s, box-shadow 0.2s;
}
.kz-eq textarea { resize: vertical; min-height: 110px; line-height: 1.5; }
.kz-eq input::placeholder, .kz-eq textarea::placeholder { color: var(--eq-muted); }
.kz-eq input:focus, .kz-eq textarea:focus {
  outline: none; border-color: var(--eq-accent);
  box-shadow: 0 0 0 3px rgba(56,182,255,0.18);
}
.kz-eq input.kz-eq-invalid { border-color: var(--eq-error); }

.kz-eq-group + .kz-eq-group { margin-top: 16px; }
.kz-eq-group-h {
  font-size: 0.68rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--eq-accent); margin: 0 0 10px;
}
.kz-eq-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.kz-eq-chips-solo { margin-top: 16px; }
.kz-eq-chip { position: relative; display: inline-flex; }
.kz-eq-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.kz-eq-chip label {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer; user-select: none;
  min-height: 40px; padding: 8px 15px; border-radius: 100px;
  font-size: 0.84rem; font-weight: 500; color: var(--eq-text);
  background: var(--eq-field); border: 1px solid var(--eq-field-border);
  transition: border-color 0.18s, background 0.18s, color 0.18s;
}
.kz-eq-chip label:hover { border-color: rgba(56,182,255,0.45); }
.kz-eq-chip input:checked + label {
  background: rgba(56,182,255,0.14); border-color: var(--eq-accent); color: var(--eq-text);
}
.kz-eq-chip input[type="checkbox"]:checked + label::before {
  content: ''; width: 9px; height: 5px; margin-top: -3px;
  border-left: 2px solid var(--eq-accent); border-bottom: 2px solid var(--eq-accent);
  transform: rotate(-45deg);
}
.kz-eq-chip input:focus-visible + label { outline: 2px solid var(--eq-accent); outline-offset: 2px; }
.kz-eq-set.kz-eq-invalid .kz-eq-chip label { border-color: var(--eq-error); }

.kz-eq-err { font-size: 0.8rem; color: var(--eq-error); margin: 0; min-height: 0; }
.kz-eq-err:empty { display: none; }
.kz-eq-set .kz-eq-err { margin-top: 10px; }

.kz-eq-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.kz-eq-submit {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--eq-accent); color: #ffffff; border: 0; cursor: pointer;
  font: inherit; font-weight: 700; font-size: 0.92rem;
  padding: 15px 30px; border-radius: 100px;
  transition: background 0.25s, color 0.25s, transform 0.2s, box-shadow 0.2s;
}
.kz-eq-submit:hover:not(:disabled) { background: #ffffff; color: #080808; transform: translateY(-2px); box-shadow: 0 10px 36px rgba(56,182,255,0.25); }
[data-theme="light"] .kz-eq-submit:hover:not(:disabled) { background: #0a0a0a; color: #ffffff; }
.kz-eq-submit svg { transition: transform 0.3s cubic-bezier(0.16,1,0.3,1); }
.kz-eq-submit:hover:not(:disabled) svg { transform: rotate(-45deg); }
.kz-eq-submit:disabled { opacity: 0.6; cursor: wait; }
.kz-eq-submit:focus-visible { outline: 2px solid var(--eq-accent); outline-offset: 3px; }

.kz-eq-status { font-size: 0.88rem; margin: -12px 0 0; }
.kz-eq-status:empty { display: none; }
.kz-eq-status-err { color: var(--eq-error); }
.kz-eq-status a, .kz-eq-small a { color: var(--eq-accent); text-decoration: underline; }
.kz-eq-small { font-size: 0.78rem; color: var(--eq-muted); line-height: 1.6; margin: -8px 0 0; }

@media (max-width: 600px) {
  .kz-eq-grid { grid-template-columns: 1fr; }
  .kz-eq-actions .kz-eq-submit { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .kz-eq *, .kz-eq-submit { transition: none !important; }
}
