// inquiry.jsx — Two inquiry form variations
function InquiryPage({ navigate, accent, inquiryStyle, setInquiryStyle, inquiryVariationLocked }) {
return (
{/* Variation toggle — hidden when locked to the chosen direction */}
{!inquiryVariationLocked && (
Variation
setInquiryStyle('dialogue')} style={{
background: 'transparent', border: 'none', cursor: 'pointer',
fontFamily: 'Inter', fontSize: 10, letterSpacing: '0.22em', textTransform: 'uppercase',
color: inquiryStyle === 'dialogue' ? accent : '#111',
borderBottom: inquiryStyle === 'dialogue' ? `1px solid ${accent}` : '1px solid transparent',
paddingBottom: 2,
}}>A · Dialogue
setInquiryStyle('letter')} style={{
background: 'transparent', border: 'none', cursor: 'pointer',
fontFamily: 'Inter', fontSize: 10, letterSpacing: '0.22em', textTransform: 'uppercase',
color: inquiryStyle === 'letter' ? accent : '#111',
borderBottom: inquiryStyle === 'letter' ? `1px solid ${accent}` : '1px solid transparent',
paddingBottom: 2,
}}>B · Letter
)}
{inquiryStyle === 'dialogue'
?
:
}
);
}
/* -------- VARIATION A — Conversational, one question at a time -------- */
function InquiryDialogue({ navigate, accent }) {
const ref = useReveal();
const isMobile = useIsMobile();
const questions = [
{ id: 'name', prompt: 'How shall we address you?', sub: 'A name, in your own hand.', type: 'text', placeholder: 'Your given name' },
{ id: 'introduction', prompt: 'Who made the introduction?', sub: 'We accept commissions by referral. Name the party — or write “a gentle exception.”', type: 'text', placeholder: 'A name, or a note' },
{ id: 'discipline', prompt: 'Which discipline do you seek?', sub: 'Choose as many as feel true.', type: 'chips', multi: true, other: true, options: ['A Wedding', 'A Gala', 'A Private Assembly', 'A Retreat', 'A Sanctuary', 'Continuum'] },
{ id: 'when', prompt: 'And when, approximately?', sub: 'A season will do.', type: 'chips', options: ['Spring', 'Summer', 'Autumn', 'Winter', 'Open to counsel'] },
{ id: 'guests', prompt: 'For how many?', sub: 'Intimacy is often underestimated.', type: 'chips', options: ['≤ 12', '12 – 40', '40 – 120', '120 +'] },
{ id: 'where', prompt: 'Where, if anywhere?', sub: 'A region, a country, or simply — you decide.', type: 'text', placeholder: 'Anywhere in the world, or leave it to us' },
{ id: 'letter', prompt: 'Finally — in a few lines, what should we know?', sub: 'Write to us as you would to a trusted correspondent.', type: 'textarea', placeholder: 'We are listening…' },
];
const [i, setI] = React.useState(0);
const [answers, setAnswers] = React.useState({});
const [done, setDone] = React.useState(false);
const q = questions[i];
const setA = (v) => setAnswers({ ...answers, [q.id]: v });
const val = answers[q.id];
const otherKey = q.id + '__other';
const otherVal = answers[otherKey] || '';
const setOther = (v) => setAnswers({ ...answers, [otherKey]: v });
const canAdvance = (() => {
if (q.type !== 'chips') return !!val && val.trim().length > 0;
if (q.multi) {
const picks = Array.isArray(val) ? val : [];
const hasOther = picks.includes('Other');
if (hasOther) return picks.length > 1 || otherVal.trim().length > 0;
return picks.length > 0;
}
if (val === 'Other') return otherVal.trim().length > 0;
return !!val;
})();
const next = () => {
if (i < questions.length - 1) setI(i + 1);
else setDone(true);
};
if (done) {
return (
Thank you.The dialogue has begun.
A member of the collective will write to you within three days — at the address you have shared, and never from anywhere else.
navigate('home')}>Return to the Threshold
Reference
CAJE · {new Date().getFullYear()} · {Math.random().toString(36).slice(2, 8).toUpperCase()}
);
}
return (
{/* progress */}
{questions.map((_, idx) => (
))}
{String(i + 1).padStart(2, '0')}
of {String(questions.length).padStart(2, '0')}
{q.prompt}
{q.sub}
{q.type === 'text' && (
setA(e.target.value)}
onKeyDown={(e) => e.key === 'Enter' && canAdvance && next()}
autoFocus
style={{
width: '100%', maxWidth: 680, padding: '16px 0',
border: 'none', borderBottom: '1px solid rgba(17,17,17,0.3)',
background: 'transparent', outline: 'none',
fontFamily: 'EB Garamond, serif', fontStyle: 'italic',
fontSize: isMobile ? 24 : 32, color: '#111', letterSpacing: '-0.005em',
}} />
)}
{q.type === 'textarea' && (
{i > 0 && (
setI(i - 1)} style={{
background: 'transparent', border: 'none', cursor: 'pointer',
fontFamily: 'Inter', fontSize: 11, letterSpacing: '0.28em', textTransform: 'uppercase',
color: '#6B6257',
display: 'flex', alignItems: 'center', gap: 12,
}}>
Previous
)}
canAdvance && next()} dark={canAdvance}>
{i === questions.length - 1 ? 'Transmit' : 'Continue'}
↵ Enter
);
}
/* -------- VARIATION B — Long-form editorial letter, all on one page -------- */
function InquiryLetter({ navigate, accent }) {
const ref = useReveal();
const isMobile = useIsMobile();
const [submitted, setSubmitted] = React.useState(false);
const [form, setForm] = React.useState({
name: '', email: '', phone: '',
introduction: '',
discipline: [],
season: '',
guests: '',
where: '',
letter: '',
});
const setF = (k, v) => setForm({ ...form, [k]: v });
const toggleD = (d) => setF('discipline', form.discipline.includes(d)
? form.discipline.filter(x => x !== d) : [...form.discipline, d]);
if (submitted) {
const reference = React.useMemo(() =>
'CAJE-' + new Date().getFullYear() + '-' +
Math.random().toString(36).slice(2, 6).toUpperCase() + '-' +
Math.random().toString(36).slice(2, 6).toUpperCase(), []);
const today = new Date().toLocaleDateString('en-GB', { day: '2-digit', month: 'long', year: 'numeric' });
return (
{/* Bordered editorial card */}
{/* Inner gold frame */}
{/* Stamp / mark */}
{/* Headline */}
Thank you.
We will reach out soon.
{/* Body copy */}
A member of the collective will write to you within three days — at the address you have shared, and never from anywhere else. Please watch your correspondence; our notes have been known to rest quietly among the unread.
{/* Reference card */}
Response
Within three days
{/* Signature */}
{/* Actions outside the card */}
navigate('home')}>Return to the Threshold
navigate('about')}>The Collective
Should you wish to add anything further, write to us directly at private@cajecollective.com .
);
}
return (
{/* Header */}
A letter — in your own hand.
We prefer language to forms; sensibility to check-boxes. Write as you would to a trusted correspondent — a few lines are enough to begin.
{/* Letter as editorial layout */}
{/* Side column */}
{/* Form */}
);
}
function FieldSet({ num, title, children }) {
return (
);
}
function Row({ children }) {
const isMobile = useIsMobile();
return {children}
;
}
function LabelRow({ text, sub }) {
return (
);
}
function Field({ label, value, onChange, type = 'text', placeholder, optional }) {
return (
onChange(e.target.value)} placeholder={placeholder}
style={{
width: '100%', padding: '10px 0', border: 'none',
borderBottom: '1px solid rgba(17,17,17,0.2)',
background: 'transparent', outline: 'none',
fontFamily: 'EB Garamond, serif', fontStyle: 'italic',
fontSize: 22, color: '#111',
}} />
);
}
function Chip({ children, active, onClick, accent }) {
return (
{children}
);
}
Object.assign(window, { InquiryPage });