Freelancer Registration – DCP Global
:root {
--navy: #152238;
--navy-mid: #1e3352;
--navy-light: #2a4a6b;
--accent: #4a90c4;
--accent-light: #6aadd4;
--white: #ffffff;
--gray-light: #f4f6f9;
--gray-border: #d8e2ee;
--text-dark: #1a2b3c;
--text-mid: #4a5a6b;
--text-light: #7a8a9a;
--success: #2ecc71;
--error: #e74c3c;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
font-family: 'DM Sans', sans-serif;
background: var(--gray-light);
color: var(--text-dark);
min-height: 100vh;
}
/* Header */
.form-header {
background: var(--navy);
padding: 32px 40px;
text-align: center;
position: relative;
overflow: hidden;
}
.form-header::before {
content: '';
position: absolute;
top: -60px; right: -60px;
width: 200px; height: 200px;
border-radius: 50%;
background: rgba(74,144,196,0.15);
}
.form-header::after {
content: '';
position: absolute;
bottom: -40px; left: -40px;
width: 150px; height: 150px;
border-radius: 50%;
background: rgba(74,144,196,0.1);
}
.form-header h1 {
font-family: 'Playfair Display', serif;
color: var(--white);
font-size: 2rem;
letter-spacing: 0.5px;
position: relative;
z-index: 1;
}
.form-header p {
color: rgba(255,255,255,0.7);
font-size: 0.95rem;
margin-top: 8px;
font-weight: 300;
position: relative;
z-index: 1;
}
/* Progress Bar */
.progress-wrapper {
background: var(--white);
border-bottom: 1px solid var(--gray-border);
padding: 20px 40px;
position: sticky;
top: 0;
z-index: 100;
box-shadow: 0 2px 12px rgba(21,34,56,0.08);
}
.steps {
display: flex;
align-items: center;
justify-content: center;
gap: 0;
max-width: 600px;
margin: 0 auto;
}
.step {
display: flex;
flex-direction: column;
align-items: center;
gap: 6px;
flex: 1;
position: relative;
}
.step:not(:last-child)::after {
content: '';
position: absolute;
top: 16px;
left: 60%;
width: 80%;
height: 2px;
background: var(--gray-border);
transition: background 0.4s;
}
.step.completed:not(:last-child)::after { background: var(--accent); }
.step-circle {
width: 32px; height: 32px;
border-radius: 50%;
background: var(--gray-border);
color: var(--text-light);
font-size: 0.8rem;
font-weight: 600;
display: flex; align-items: center; justify-content: center;
transition: all 0.3s;
position: relative;
z-index: 1;
}
.step.active .step-circle { background: var(--navy); color: white; }
.step.completed .step-circle { background: var(--accent); color: white; }
.step-label {
font-size: 0.72rem;
color: var(--text-light);
font-weight: 500;
text-align: center;
white-space: nowrap;
}
.step.active .step-label { color: var(--navy); font-weight: 600; }
.step.completed .step-label { color: var(--accent); }
/* Form Container */
.form-container {
max-width: 760px;
margin: 40px auto;
padding: 0 20px 60px;
}
.form-section {
display: none;
animation: fadeIn 0.4s ease;
}
.form-section.active { display: block; }
@keyframes fadeIn {
from { opacity: 0; transform: translateY(16px); }
to { opacity: 1; transform: translateY(0); }
}
.section-title {
font-family: 'Playfair Display', serif;
font-size: 1.5rem;
color: var(--navy);
margin-bottom: 6px;
}
.section-subtitle {
color: var(--text-mid);
font-size: 0.9rem;
margin-bottom: 32px;
font-weight: 300;
}
/* Cards */
.card {
background: var(--white);
border-radius: 12px;
padding: 28px 32px;
margin-bottom: 20px;
border: 1px solid var(--gray-border);
box-shadow: 0 2px 8px rgba(21,34,56,0.04);
}
.card-title {
font-size: 0.75rem;
text-transform: uppercase;
letter-spacing: 1.5px;
color: var(--accent);
font-weight: 600;
margin-bottom: 20px;
}
/* Fields */
.field-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
margin-bottom: 16px;
}
.field-row.single { grid-template-columns: 1fr; }
.field-row.triple { grid-template-columns: 1fr 1fr 1fr; }
.field {
display: flex;
flex-direction: column;
gap: 6px;
margin-bottom: 16px;
}
.field:last-child { margin-bottom: 0; }
label {
font-size: 0.82rem;
font-weight: 600;
color: var(--text-dark);
letter-spacing: 0.2px;
}
label .required { color: var(--accent); margin-left: 2px; }
label .hint {
display: block;
font-weight: 300;
font-size: 0.78rem;
color: var(--text-light);
margin-top: 2px;
letter-spacing: 0;
}
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea {
width: 100%;
padding: 11px 14px;
border: 1.5px solid var(--gray-border);
border-radius: 8px;
font-family: 'DM Sans', sans-serif;
font-size: 0.9rem;
color: var(--text-dark);
background: var(--white);
transition: border-color 0.2s, box-shadow 0.2s;
outline: none;
appearance: none;
}
input:focus, select:focus, textarea:focus {
border-color: var(--accent);
box-shadow: 0 0 0 3px rgba(74,144,196,0.12);
}
input.error, select.error, textarea.error {
border-color: var(--error);
}
textarea { resize: vertical; min-height: 100px; line-height: 1.6; }
/* Radio / Checkbox groups */
.radio-group, .check-group {
display: flex;
flex-wrap: wrap;
gap: 10px;
margin-top: 4px;
}
.radio-group.column { flex-direction: column; gap: 8px; }
.radio-option, .check-option {
display: flex;
align-items: center;
gap: 8px;
cursor: pointer;
}
.radio-option input, .check-option input {
width: 16px; height: 16px;
accent-color: var(--navy);
cursor: pointer;
flex-shrink: 0;
}
.radio-option span, .check-option span {
font-size: 0.88rem;
color: var(--text-dark);
}
/* Fitzpatrick */
.fitz-options {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 10px;
margin-top: 4px;
}
.fitz-option {
border: 2px solid var(--gray-border);
border-radius: 10px;
padding: 12px 10px;
cursor: pointer;
transition: all 0.2s;
display: flex;
align-items: center;
gap: 10px;
}
.fitz-option:hover { border-color: var(--accent-light); }
.fitz-option.selected { border-color: var(--navy); background: rgba(21,34,56,0.03); }
.fitz-option input { display: none; }
.fitz-swatch {
width: 28px; height: 28px;
border-radius: 50%;
flex-shrink: 0;
border: 1px solid rgba(0,0,0,0.1);
}
.fitz-text { font-size: 0.78rem; color: var(--text-mid); line-height: 1.3; }
.fitz-type { font-weight: 600; color: var(--text-dark); font-size: 0.82rem; }
/* Language multiselect */
.multiselect-wrapper {
position: relative;
}
.multiselect-tags {
min-height: 44px;
border: 1.5px solid var(--gray-border);
border-radius: 8px;
padding: 6px 10px;
display: flex;
flex-wrap: wrap;
gap: 6px;
cursor: text;
transition: border-color 0.2s, box-shadow 0.2s;
background: white;
}
.multiselect-tags:focus-within {
border-color: var(--accent);
box-shadow: 0 0 0 3px rgba(74,144,196,0.12);
}
.tag {
background: var(--navy);
color: white;
padding: 3px 10px 3px 10px;
border-radius: 20px;
font-size: 0.78rem;
display: flex;
align-items: center;
gap: 6px;
}
.tag-remove {
cursor: pointer;
font-size: 0.9rem;
opacity: 0.7;
line-height: 1;
}
.tag-remove:hover { opacity: 1; }
.multiselect-input {
border: none !important;
outline: none !important;
box-shadow: none !important;
padding: 4px 6px !important;
min-width: 120px;
flex: 1;
font-size: 0.88rem;
}
.multiselect-dropdown {
position: absolute;
top: calc(100% + 4px);
left: 0; right: 0;
background: white;
border: 1.5px solid var(--gray-border);
border-radius: 8px;
max-height: 220px;
overflow-y: auto;
z-index: 200;
box-shadow: 0 8px 24px rgba(21,34,56,0.12);
display: none;
}
.multiselect-dropdown.open { display: block; }
.dropdown-option {
padding: 9px 14px;
font-size: 0.88rem;
cursor: pointer;
transition: background 0.15s;
color: var(--text-dark);
}
.dropdown-option:hover { background: var(--gray-light); }
.dropdown-option.selected { background: rgba(74,144,196,0.08); color: var(--accent); font-weight: 500; }
.dropdown-option.hidden { display: none; }
/* CV Upload box */
.upload-box {
border: 2px dashed var(--gray-border);
border-radius: 10px;
padding: 32px 20px;
text-align: center;
cursor: pointer;
transition: all 0.2s;
background: var(--gray-light);
}
.upload-box:hover { border-color: var(--accent); background: rgba(74,144,196,0.04); }
.upload-box input { display: none; }
.upload-icon { font-size: 2rem; margin-bottom: 8px; }
.upload-box p { font-size: 0.88rem; color: var(--text-mid); }
.upload-box strong { color: var(--accent); }
.upload-note {
font-size: 0.78rem;
color: var(--text-light);
margin-top: 8px;
display: block;
}
.upload-info {
background: rgba(74,144,196,0.08);
border: 1px solid rgba(74,144,196,0.2);
border-radius: 8px;
padding: 14px 16px;
margin-top: 12px;
font-size: 0.84rem;
color: var(--navy-mid);
line-height: 1.6;
}
.upload-info strong { color: var(--navy); }
/* Buttons */
.btn-row {
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 32px;
gap: 12px;
}
.btn {
padding: 13px 32px;
border-radius: 8px;
font-family: 'DM Sans', sans-serif;
font-size: 0.92rem;
font-weight: 600;
cursor: pointer;
border: none;
transition: all 0.2s;
letter-spacing: 0.3px;
}
.btn-primary {
background: var(--navy);
color: white;
}
.btn-primary:hover { background: var(--navy-mid); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(21,34,56,0.25); }
.btn-secondary {
background: transparent;
color: var(--text-mid);
border: 1.5px solid var(--gray-border);
}
.btn-secondary:hover { border-color: var(--navy); color: var(--navy); }
.btn-submit {
background: var(--accent);
color: white;
padding: 14px 40px;
}
.btn-submit:hover { background: var(--accent-light); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(74,144,196,0.35); }
/* Success screen */
.success-screen {
display: none;
text-align: center;
padding: 60px 40px;
}
.success-screen.active { display: block; }
.success-icon {
width: 72px; height: 72px;
background: var(--success);
border-radius: 50%;
display: flex; align-items: center; justify-content: center;
font-size: 2rem;
margin: 0 auto 24px;
color: white;
}
.success-screen h2 {
font-family: 'Playfair Display', serif;
font-size: 1.8rem;
color: var(--navy);
margin-bottom: 12px;
}
.success-screen p { color: var(--text-mid); line-height: 1.7; max-width: 480px; margin: 0 auto; }
/* Error message */
.error-msg {
font-size: 0.78rem;
color: var(--error);
margin-top: 4px;
display: none;
}
.error-msg.visible { display: block; }
@media (max-width: 600px) {
.field-row { grid-template-columns: 1fr; }
.field-row.triple { grid-template-columns: 1fr 1fr; }
.fitz-options { grid-template-columns: 1fr 1fr; }
.form-header { padding: 24px 20px; }
.card { padding: 20px 18px; }
.progress-wrapper { padding: 16px 20px; }
.step-label { font-size: 0.65rem; }
}
// ---- Language & CAT Tool lists ----
const languages = ["Afrikaans","Albanian","Amharic","Arabic","Armenian","Azerbaijani","Basque","Belarusian","Bengali","Bosnian","Bulgarian","Catalan","Cebuano","Chichewa","Chinese","Corsican","Croatian","Czech","Danish","Dutch","English","Esperanto","Estonian","Filipino","Finnish","French","Frisian","Galician","Georgian","German","Greek","Gujarati","Haitian Creole","Hausa","Hawaiian","Hebrew","Hindi","Hmong","Hungarian","Icelandic","Igbo","Indonesian","Irish","Italian","Japanese","Javanese","Kannada","Kazakh","Khmer","Kinyarwanda","Korean","Kurdish (Kurmanji)","Kyrgyz","Lao","Latin","Latvian","Lithuanian","Luxembourgish","Macedonian","Malagasy","Malay","Malayalam","Maltese","Maori","Marathi","Mongolian","Myanmar (Burmese)","Nepali","Norwegian","Odia (Oriya)","Pashto","Persian","Polish","Portuguese","Punjabi","Romanian","Russian","Samoan","Scots Gaelic","Serbian","Sesotho","Shona","Sindhi","Sinhala","Slovak","Slovenian","Somali","Spanish","Sundanese","Swahili","Swedish","Tajik","Tamil","Telugu","Thai","Turkish","Ukrainian","Urdu","Uyghur","Uzbek","Vietnamese","Welsh","Xhosa","Yiddish","Yoruba","Zulu","Other (please specify)"];
const catTools = ["SDL Trados Studio","MemoQ","Wordfast","OmegaT","CafeTran","Deja Vu","Memsource","Smartcat","XTM Cloud","Transifex","Crowdin","MateCat","Lingotek","iTranslate","Phrase","Poedit","Fluency Now","CATMate","Across","TextUnited","Lokalise","Gengo","Linguee","Google Translate Toolkit","Subtitle Edit","SRT Translator","Smartling","Wordbee","SDL Passolo","Trados GroupShare","None"];
const multiselects = {
'native-lang': { options: languages, selected: [] },
'translate-lang': { options: languages, selected: [] },
'cat-tools': { options: catTools, selected: [] }
};
function buildDropdowns() {
for (const key in multiselects) {
const dd = document.getElementById(key + '-dropdown');
multiselects[key].options.forEach(opt => {
const div = document.createElement('div');
div.className = 'dropdown-option';
div.dataset.value = opt;
div.textContent = opt;
div.onmousedown = (e) => { e.preventDefault(); toggleOption(key, opt); };
dd.appendChild(div);
});
}
}
function focusInput(id) { document.getElementById(id).focus(); }
function openDropdown(key) {
document.getElementById(key + '-dropdown').classList.add('open');
}
function closeDropdown(key) {
setTimeout(() => {
document.getElementById(key + '-dropdown').classList.remove('open');
document.getElementById(key + '-input').value = '';
filterOptions(key);
}, 200);
}
function filterOptions(key) {
const query = document.getElementById(key + '-input').value.toLowerCase();
const opts = document.querySelectorAll('#' + key + '-dropdown .dropdown-option');
opts.forEach(opt => {
const matches = opt.dataset.value.toLowerCase().includes(query);
opt.classList.toggle('hidden', !matches);
});
}
function toggleOption(key, value) {
const sel = multiselects[key].selected;
const idx = sel.indexOf(value);
if (idx > -1) {
sel.splice(idx, 1);
} else {
sel.push(value);
}
renderTags(key);
updateDropdownSelected(key);
}
function renderTags(key) {
const container = document.getElementById(key + '-tags');
const input = document.getElementById(key + '-input');
// remove existing tags
container.querySelectorAll('.tag').forEach(t => t.remove());
multiselects[key].selected.forEach(val => {
const tag = document.createElement('div');
tag.className = 'tag';
tag.innerHTML = val + '
×';
container.insertBefore(tag, input);
});
}
function updateDropdownSelected(key) {
const sel = multiselects[key].selected;
document.querySelectorAll('#' + key + '-dropdown .dropdown-option').forEach(opt => {
opt.classList.toggle('selected', sel.includes(opt.dataset.value));
});
}
// ---- Fitzpatrick ----
function selectFitz(el, val) {
document.querySelectorAll('.fitz-option').forEach(f => f.classList.remove('selected'));
el.classList.add('selected');
}
// ---- Payment fields toggle ----
function showPaymentFields() {
const val = document.querySelector('input[name="payment"]:checked')?.value;
document.getElementById('payment-email-block').style.display = (val === 'PayPal' || val === 'Payoneer') ? 'block' : 'none';
document.getElementById('bank-details-block').style.display = (val === 'BSB Transfer (Australia Only)' || val === 'International Wire Transfer') ? 'block' : 'none';
}
// ---- Navigation ----
function nextStep(current) {
if (!validateStep(current)) return;
document.getElementById('section-' + current).classList.remove('active');
document.getElementById('section-' + (current + 1)).classList.add('active');
document.getElementById('step-ind-' + current).classList.remove('active');
document.getElementById('step-ind-' + current).classList.add('completed');
document.getElementById('step-ind-' + (current + 1)).classList.add('active');
window.scrollTo({ top: 0, behavior: 'smooth' });
}
function prevStep(current) {
document.getElementById('section-' + current).classList.remove('active');
document.getElementById('section-' + (current - 1)).classList.add('active');
document.getElementById('step-ind-' + current).classList.remove('active');
document.getElementById('step-ind-' + (current - 1)).classList.remove('completed');
document.getElementById('step-ind-' + (current - 1)).classList.add('active');
window.scrollTo({ top: 0, behavior: 'smooth' });
}
// ---- Validation ----
function showError(id, show) {
const el = document.getElementById('err-' + id);
if (el) el.classList.toggle('visible', show);
const input = document.getElementById(id);
if (input) input.classList.toggle('error', show);
}
function validateStep(step) {
let valid = true;
if (step === 1) {
if (!document.getElementById('first-name').value.trim()) { showError('first-name', true); valid = false; } else { showError('first-name', false); }
if (!document.getElementById('last-name').value.trim()) { showError('last-name', true); valid = false; } else { showError('last-name', false); }
if (!document.querySelector('input[name="gender"]:checked')) { showError('gender', true); valid = false; } else { showError('gender', false); }
if (!document.getElementById('dob').value) { showError('dob', true); valid = false; } else { showError('dob', false); }
if (!document.getElementById('phone').value.trim()) { showError('phone', true); valid = false; } else { showError('phone', false); }
const email = document.getElementById('email').value.trim();
const emailConf = document.getElementById('email-confirm').value.trim();
if (!email || !email.includes('@')) { showError('email', true); valid = false; } else { showError('email', false); }
if (email !== emailConf) { showError('email-confirm', true); valid = false; } else { showError('email-confirm', false); }
if (!document.getElementById('birth-country').value) { showError('birth-country', true); valid = false; } else { showError('birth-country', false); }
if (!document.getElementById('city').value.trim()) { showError('city', true); valid = false; } else { showError('city', false); }
if (!document.getElementById('country').value) { showError('country', true); valid = false; } else { showError('country', false); }
if (!document.querySelector('input[name="device"]:checked')) { showError('device', true); valid = false; } else { showError('device', false); }
if (!document.querySelector('input[name="fitzpatrick"]:checked')) { showError('fitz', true); valid = false; } else { showError('fitz', false); }
}
if (step === 2) {
if (!document.querySelector('input[name="payment"]:checked')) { showError('payment', true); valid = false; } else { showError('payment', false); }
}
if (step === 3) {
if (multiselects['native-lang'].selected.length === 0) { showError('native-lang', true); valid = false; } else { showError('native-lang', false); }
if (multiselects['translate-lang'].selected.length === 0) { showError('translate-lang', true); valid = false; } else { showError('translate-lang', false); }
['trans-exp','trans-script-exp','subtitle-exp','interp-exp','voice-exp','annot-exp'].forEach(id => {
if (!document.getElementById(id).value.trim()) { showError(id, true); valid = false; } else { showError(id, false); }
});
if (!document.getElementById('education').value) { showError('education', true); valid = false; } else { showError('education', false); }
if (!document.getElementById('how-heard').value) { showError('how-heard', true); valid = false; } else { showError('how-heard', false); }
const cvLink = document.getElementById('cv-link').value.trim();
if (!cvLink || !cvLink.includes('drive.google.com')) { showError('cv-link', true); valid = false; } else { showError('cv-link', false); }
}
return valid;
}
// ---- Submit ----
function submitForm() {
if (!validateStep(3)) return;
// Collect all data
const data = {
Name: document.getElementById('first-name').value.trim() + ' ' + document.getElementById('last-name').value.trim(),
Gender: document.querySelector('input[name="gender"]:checked')?.value || '',
DOB: document.getElementById('dob').value,
Phone: document.getElementById('phone-code').value + ' ' + document.getElementById('phone').value.trim(),
Whatsapp: document.getElementById('whatsapp').value.trim() ? document.getElementById('whatsapp-code').value + ' ' + document.getElementById('whatsapp').value.trim() : '',
Email: document.getElementById('email').value.trim(),
'Where Were You Born': document.getElementById('birth-country').value,
'Current Address': document.getElementById('city').value + ', ' + document.getElementById('state').value + ', ' + document.getElementById('country').value,
'Mobile Device': (() => {
const brand = document.querySelector('input[name="device"]:checked')?.value || '';
const otherBrand = document.getElementById('device-other-brand').value.trim();
const model = document.getElementById('device-model').value.trim();
const finalBrand = brand === 'Other' ? otherBrand : brand;
return model ? finalBrand + ' - ' + model : finalBrand;
})(),
Fitzpatrick: document.querySelector('input[name="fitzpatrick"]:checked')?.value || '',
'Payment Preferred': document.querySelector('input[name="payment"]:checked')?.value || '',
'Payment Email': document.getElementById('payment-email').value.trim(),
'Bank Details': document.getElementById('bank-details').value.trim(),
'Native Language': multiselects['native-lang'].selected.join(', '),
'Translate To': multiselects['translate-lang'].selected.join(', '),
'CAT Tools': multiselects['cat-tools'].selected.join(', '),
'Trans Exp': document.getElementById('trans-exp').value.trim(),
'Transcription Exp': document.getElementById('trans-script-exp').value.trim(),
'Subtitle Exp': document.getElementById('subtitle-exp').value.trim(),
'Interp Exp': document.getElementById('interp-exp').value.trim(),
'Voice Rec Exp': document.getElementById('voice-exp').value.trim(),
'Annot Exp': document.getElementById('annot-exp').value.trim(),
Education: document.getElementById('education').value,
'How Did you Hear': document.getElementById('how-heard').value,
CV: document.getElementById('cv-link').value.trim(),
'Email Opt-In': document.getElementById('email-optin').checked ? 'Yes' : 'No',
IP: userIp,
'IP Country': ipCountry
};
// POST to Google Apps Script
const SCRIPT_URL = 'https://script.google.com/macros/s/AKfycby346tsXphEZFzho5yEElnElVxn-9QlmcFvYo9ymUWniqDhMSPOk7xrcn_nyAXc5Z7_-w/exec';
fetch(SCRIPT_URL, {
method: 'POST',
mode: 'no-cors',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify(data)
}).catch(() => {});
// Show success
document.getElementById('section-3').classList.remove('active');
document.getElementById('step-ind-3').classList.add('completed');
document.getElementById('success-screen').classList.add('active');
window.scrollTo({ top: 0, behavior: 'smooth' });
}
// ── IP Lookup (client-side) ──────────────────────────────────
let userIp = 'N/A', ipCountry = 'N/A';
fetch('https://api.ipify.org?format=json')
.then(r => r.json())
.then(d => {
userIp = d.ip || 'N/A';
return fetch('https://ipinfo.io/' + userIp + '?token=c23b8de982dce3');
})
.then(r => r.json())
.then(d => { ipCountry = d.country || 'N/A'; })
.catch(() => {});
// ---- Device model ----
function showDeviceModel(radio) {
document.getElementById('device-model-block').style.display = 'block';
const otherField = document.getElementById('other-brand-field');
otherField.style.display = radio.value === 'Other' ? 'block' : 'none';
if (radio.value !== 'Other') {
document.getElementById('device-other-brand').value = '';
}
}
const SPREADSHEET_ID = '1uqfvBHDW-ih1hQdvYbeQcOOYFfkjrL6cGrOT2vdHbzM';
buildDropdowns();