The Parliament – Afghanistan Youth Parliament for Freedom, Rebuilding and Sustainability
https://cdn.tailwindcss.com
body {
box-sizing: border-box;
}
:root {
–greenwood-primary: #2d5016;
–greenwood-light: #4a7c59;
–greenwood-lighter: #6b8e5a;
–greenwood-bg: #f0f7ed;
}
.greenwood-primary { color: var(–greenwood-primary); }
.bg-greenwood-primary { background-color: var(–greenwood-primary); }
.greenwood-light { color: var(–greenwood-light); }
.bg-greenwood-light { background-color: var(–greenwood-light); }
.bg-greenwood-bg { background-color: var(–greenwood-bg); }
.border-greenwood { border-color: var(–greenwood-primary); }
.hero-gradient {
background: linear-gradient(135deg, var(–greenwood-primary) 0%, var(–greenwood-light) 100%);
}
.card-hover {
transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-hover:hover {
transform: translateY(-4px);
box-shadow: 0 20px 25px -5px rgba(45, 80, 22, 0.1);
}
.lang-selector {
font-family: ‘Segoe UI’, Tahoma, Geneva, Verdana, sans-serif;
}
.rtl { direction: rtl; text-align: right; }
.ltr { direction: ltr; text-align: left; }
.flowchart-step {
position: relative;
}
.flowchart-step::after {
content: ‘→’;
position: absolute;
right: -30px;
top: 50%;
transform: translateY(-50%);
color: var(–greenwood-light);
font-size: 24px;
font-weight: bold;
}
.flowchart-step:last-child::after {
display: none;
}
@media (max-width: 768px) {
.flowchart-step::after {
content: ‘↓’;
right: 50%;
top: 100%;
transform: translateX(50%);
bottom: -20px;
}
}
فا
پښ
Afghanistan Youth Parliament
For Freedom, Rebuilding & Sustainability
فا
پښ
Witness Democracy in Action
This is the heart of our democratic process. Here, you can watch live as elected representatives from across Afghanistan debate and shape the policies for our nation’s future.
Live Stream
The next parliamentary session will be scheduled soon. Stay tuned for live debates and votes.
Never Miss a Session
Get notified when live sessions are scheduled. Choose your preferred method:
📧
Email Alerts
📱
WhatsApp Updates
Upcoming Sessions
Introduction to the Legislative Process
Date: To be announced
Youth Representation in Democracy
Date: To be announced
Past Sessions Archive
Founding Session – Vision & Mission
Duration: 2 hours 15 minutes
View Session Minutes & Recording
Committee Formation Session
Duration: 1 hour 45 minutes
View Session Minutes & Recording
Directory of Representatives
Meet the dedicated young leaders representing Afghanistan’s diverse communities and working towards a brighter future.
Total Districts
Provinces
Rural Districts
Urban Districts
Find Your Representative
All Provinces
Kabul (15 districts)
Herat (15 districts)
Nangarhar (22 districts)
Balkh (14 districts)
Kandahar (16 districts)
Ghor (10 districts)
Laghman (6 districts)
Kunduz (6 districts)
Paktia (14 districts)
Zabul (11 districts)
Baghlan (15 districts)
Badakhshan (28 districts)
Bamyan (8 districts)
Badghis (7 districts)
Wardak (9 districts)
Logar (7 districts)
Samangan (7 districts)
Takhar (17 districts)
Nuristan (8 districts)
Faryab (13 districts)
Sar-e Pul (7 districts)
Paktika (19 districts)
Farah (11 districts)
Helmand (15 districts)
Nimroz (5 districts)
Ghazni (20 districts)
Uruzgan (6 districts)
Kapisa (6 districts)
Parwan (9 districts)
Panjshir (8 districts)
Jowzjan (11 districts)
Khost (13 districts)
Kunar (15 districts)
Daykundi (9 districts)
All Districts
Representative A
Kabul Province – Kabul District
Focusing on education reform and youth empowerment initiatives.
Representative B
Herat Province – Injil District
Advocating for women’s rights and economic development programs.
Representative C
Balkh Province – Balkh District
Working on infrastructure development and rural connectivity projects.
District Representatives Network
Afghanistan has 401 districts across 34 provinces. Each district will have dedicated representatives ensuring every community has a voice in parliament.
Kabul Center District
Population: ~850,000
Representative: Ahmad Shah Masood (Pending Election)
High Density
Injil District, Herat
Population: ~245,000
Representative: Maryam Herati (Pending Election)
Border Region
Wakhan District, Badakhshan
Population: ~12,000
Representative: Noor Ahmad Wakhi (Pending Election)
Minority Language
View All Representatives
How a Policy is Born
Our transparent and rigorous process ensures every voice is heard and every policy is built on debate and consensus.
Idea & Draft
A Representative or Citizen submits a policy idea.
Committee Review
A specialized committee debates and refines the draft.
Plenary Debate
The full Parliament debates the proposal in a live session.
Voting & Adoption
Representatives vote. A majority passes the policy.
Implementation
Relevant Chambers of Expertise develop an action plan to implement the passed policy.
Current Legislation in Process
Youth Education Enhancement Act
Committee Review
Improving access to quality education and vocational training for Afghan youth.
Track Progress
Rural Development Initiative
Plenary Debate
Supporting infrastructure and economic opportunities in rural communities.
Track Progress
The Grassroots Connection
The Village Liaison Network is the vital link between every community and the Federal Parliament. Liaisons are trusted individuals who gather local concerns, share information from the Parliament, and ensure no voice is left unheard.
How It Works
Community Listening
Liaisons regularly meet with community members to understand local needs and concerns.
Information Sharing
They communicate parliamentary decisions and upcoming policies back to their communities.
Advocacy & Representation
Liaisons advocate for their communities’ interests in parliamentary discussions and policy development.
Network Statistics
Provinces Covered
Active Liaisons
Villages Connected
Monthly Reports
Recent Community Feedback
‘The liaison program has given our village a direct voice in parliament. We feel heard and represented for the first time.’ – Village Elder, Bamyan Province
Join the Network
Are you passionate about serving your community and bridging the gap between local needs and national policy? Become a Village Liaison and make a real difference.
Apply to Become a Village Liaison
Applications are reviewed monthly. Training and support provided.
Shape Your Future. Run for Office.
The next election cycle for District Representatives will be announced here. Prepare to make a difference.
Upcoming Election Timeline
Nomination Period Opens
Date: To be announced
Campaign Period
Duration: 60 days
Election Day
Voting opens nationwide
Candidate Resources
Election Guidelines
Complete guide to the nomination process, eligibility requirements, and campaign rules.
Download PDF
Learn About the Role of a Representative
Understand the responsibilities, duties, and impact of serving as a district representative.
Read More
Campaign Training Workshop
Free training sessions on effective campaigning, public speaking, and community engagement.
Register Now
Voter Information
Voter Registration
Register to vote and make your voice heard in shaping Afghanistan’s future.
Check Registration Status
Voting Process
Learn about the voting process, polling locations, and what to expect on election day.
Learn More
Election Security
Information about measures in place to ensure fair, transparent, and secure elections.
Read Security Report
Ready to Serve Your Community?
Democracy thrives when passionate individuals step forward to lead. Your community needs your voice, your ideas, and your commitment to positive change.
Subscribe to Updates
// Language switching functionality
let currentLanguage = ‘en’;
function switchLanguage(lang) {
currentLanguage = lang;
// Update header language selector buttons
document.querySelectorAll(‘.lang-selector button’).forEach(btn => {
btn.classList.remove(‘bg-white’, ‘bg-opacity-30’);
btn.classList.add(‘hover:bg-white’, ‘hover:bg-opacity-30’);
});
if (document.getElementById(`lang-${lang}`)) {
document.getElementById(`lang-${lang}`).classList.add(‘bg-white’, ‘bg-opacity-30’);
document.getElementById(`lang-${lang}`).classList.remove(‘hover:bg-white’, ‘hover:bg-opacity-30’);
}
// Update floating language selector buttons
document.querySelectorAll(‘#floating-lang-selector button’).forEach(btn => {
btn.classList.remove(‘bg-white’, ‘bg-opacity-30’);
btn.classList.add(‘hover:bg-white’, ‘hover:bg-opacity-30’);
});
document.getElementById(`float-lang-${lang}`).classList.add(‘bg-white’, ‘bg-opacity-30’);
document.getElementById(`float-lang-${lang}`).classList.remove(‘hover:bg-white’, ‘hover:bg-opacity-30’);
// Update all text elements
document.querySelectorAll(‘[data-en]’).forEach(element => {
if (element.hasAttribute(`data-${lang}`)) {
element.textContent = element.getAttribute(`data-${lang}`);
}
// Handle placeholder text for inputs
if (element.tagName === ‘INPUT’ && element.hasAttribute(`data-${lang}`)) {
element.placeholder = element.getAttribute(`data-${lang}`);
}
});
// Menu links styling is handled by CSS classes
// Update text direction for RTL languages
const body = document.body;
if (lang === ‘fa’ || lang === ‘ps’) {
body.classList.add(‘rtl’);
body.classList.remove(‘ltr’);
body.style.direction = ‘rtl’;
} else {
body.classList.add(‘ltr’);
body.classList.remove(‘rtl’);
body.style.direction = ‘ltr’;
}
}
// Mobile menu toggle
const mobileMenuBtn = document.getElementById(‘mobile-menu-btn’);
const mobileMenu = document.getElementById(‘mobile-menu’);
mobileMenuBtn.addEventListener(‘click’, () => {
mobileMenu.classList.toggle(‘hidden’);
});
// Smooth scrolling for navigation links
document.querySelectorAll(‘a[href^=”#”]’).forEach(anchor => {
anchor.addEventListener(‘click’, function (e) {
e.preventDefault();
const target = document.querySelector(this.getAttribute(‘href’));
if (target) {
target.scrollIntoView({
behavior: ‘smooth’,
block: ‘start’
});
// Close mobile menu if open
mobileMenu.classList.add(‘hidden’);
}
});
});
// Districts data – Complete list of all 34 provinces and 364 districts
const districtsData = {
kabul: [‘استالف’, ‘بگرامی’, ‘فرزه’, ‘پغمان’, ‘قره باغ’, ‘کابل’, ‘چهارآسیاب’, ‘کلکان’, ‘خاک جبار’, ‘گلدره’, ‘موسهی’, ‘ده سبز’, ‘سروبی’, ‘میربچه کوت’, ‘شکردره’],
herat: [‘ادرسکن’, ‘انجیل’, ‘اوبه’, ‘پشتون زرغون’, ‘چشت شریف’, ‘زنده جان’, ‘شینډنډ/سبزوار’, ‘غوریان’, ‘فارسی’, ‘کرخ’, ‘کشک’, ‘کشک کهنه’, ‘کهسان’, ‘گذره’, ‘گلران’],
nangarhar: [‘آچین’, ‘رودات’, ‘بټی کوټ’, ‘سرخ رود’, ‘بهسود’, ‘شیرزاد’, ‘پچیرآگام’, ‘غنی خیل’, ‘کامه’, ‘کوټ’, ‘حصارک’, ‘هسکه مینه’, ‘چپرهار’, ‘گوشته’, ‘خوگیاڼی’, ‘دربابا’, ‘لعل پور’, ‘دره نور’, ‘مهمند دره’, ‘خیوه’, ‘نازیان’, ‘سپین غر’],
balkh: [‘بلخ’, ‘چاربولک’, ‘چارکنت’, ‘چمتال’, ‘خلم’, ‘دولت آباد’, ‘دهدادی’, ‘زاری’, ‘شورتپه’, ‘شولگره’, ‘کشنده’, ‘کلدار’, ‘مارمل’, ‘نهرشاهی’],
kandahar: [‘آرغستان’, ‘شاه ولی کوټ’, ‘ارغنداب’, ‘شورابک’, ‘پنجوائی’, ‘غورک’, ‘خاکریز’, ‘دامان’, ‘معروف’, ‘ریگستان’, ‘میانشین’, ‘ژیړی’, ‘میوند’, ‘نیش’, ‘سپین بولدک’, ‘تخته پل’],
ghor: [‘فیروزکوه’, ‘تیوره’, ‘لعل و سرجنگل’, ‘دولینه’, ‘چهارسده’, ‘تولک’, ‘شهرک’, ‘ساغر’, ‘دولتیار’, ‘پسابند’],
laghman: [‘مهترلام’, ‘دولت شاه’, ‘قرغه ئی’, ‘علیشنگ’, ‘علینگار’, ‘بادپخ’],
kunduz: [‘امام صاحب’, ‘چهاردره’, ‘خان آباد’, ‘دشت آرچی’, ‘علی آباد’, ‘قلعه ذال’],
paktia: [‘گردیز’, ‘احمد آباد’, ‘جانی خیل’, ‘څمکنی’, ‘ډنډ پټان’, ‘وزی ځدراڼ’, ‘زرمت’, ‘سیدکرم’, ‘شواک’, ‘گرده څیړی’, ‘لجه احمدخیل’, ‘لجه منگل’, ‘میرزکه’, ‘ځاځى اريوب’],
zabul: [‘آتغر’, ‘ارغنداب’, ‘ترنگ و جلدک’, ‘دایچوپان’, ‘شاه جوی’, ‘شملزائی’, ‘شینکی’, ‘قلات’, ‘کاکر’, ‘میزان’, ‘نوبهار’],
baghlan: [‘نهرین’, ‘اندرآب’, ‘بغلان جدید’, ‘پل حصار’, ‘تاله و برفک’, ‘جلگه’, ‘خنجان’, ‘خوست و فرنگ’, ‘دوشی’, ‘دهانه غوری’, ‘ده صلاح’, ‘فرنگ و غارو’, ‘گذرگاه نور’, ‘برکه’, ‘بنو’],
badakhshan: [‘آرغنج خواه’, ‘شغنان’, ‘آرگو’, ‘شکی’, ‘اشکاشم’, ‘شهدا’, ‘بهارک’, ‘شهربزرگ’, ‘تگاب/کشم بالا’, ‘شهر فیض آباد’, ‘کران و منجان’, ‘تیشکان’, ‘جرم’, ‘کشم’, ‘خاش’, ‘کوف آب’, ‘خواهان’, ‘کوهستان’, ‘درایم’, ‘واخان’, ‘درواز پائین/نسی’, ‘وردج’, ‘یاوان’, ‘درواز بالا/مایمی’, ‘یفتل پائین’, ‘راغستان’, ‘یمگان/گیروان’, ‘زیباک’],
bamyan: [‘بامیان’, ‘کهمرد’, ‘پنجاب’, ‘سیغان’, ‘شیبر’, ‘ورس’, ‘یکاولنگ’, ‘یکاولنگ حصه دوم’],
badghis: [‘آب کمری’, ‘جوند’, ‘قادس’, ‘قلعه نو’, ‘بالامرغاب’, ‘مقر’, ‘غورماچ’],
wardak: [‘میدان شهر’, ‘جلریز’, ‘جغتو’, ‘چک وردک’, ‘حصه اول بهسود’, ‘دایمیرداد/جلگه’, ‘سیدآباد’, ‘مرکز بهسود’, ‘نرخ’],
logar: [‘آزره’, ‘برکی برک’, ‘پل علم’, ‘چرخ’, ‘خروار’, ‘خوشی’, ‘محمد آغه’],
samangan: [‘آیبک’, ‘حضرت سلطان’, ‘خرم و سارباغ’, ‘دره صوف بالا’, ‘دره صوف پائین’, ‘روی دو آب’, ‘فیروزنخچیر’],
takhar: [‘دشت قلعه’, ‘اشکمش’, ‘بنگی’, ‘روستاق’, ‘بهارک’, ‘فرخار’, ‘تالقان’, ‘چال’, ‘کلفگان’, ‘چاه آب’, ‘نمک آب’, ‘خواجه بهاء الدین’, ‘ورسج’, ‘خواجه غار’, ‘هزار سموچ’, ‘درقد’, ‘ینگی قلعه’],
nuristan: [‘برگ متال’, ‘پارون’, ‘دو آب’, ‘کامدیش’, ‘مندول’, ‘نورگرام’, ‘واما’, ‘وایگل’],
faryab: [‘آلمار’, ‘آندخوی’, ‘شیرین تگاب’, ‘قرغان’, ‘بلچراغ’, ‘قرم قل’, ‘پشتون کوت’, ‘قیصار’, ‘خان چارباغ’, ‘دولت آباد’, ‘کوهستان’, ‘خواجه سبزپوش ولی’, ‘گرزیوان’],
sarpul: [‘بلخاب’, ‘سرپل’, ‘سانچارک’, ‘سوزمه قلعه’, ‘صیاد’, ‘کوهستانات’, ‘گوسفندی’],
paktika: [‘آرگون’, ‘شرن’, ‘اومنه’, ‘گومل’, ‘برمل’, ‘گیان’, ‘تروو’, ‘متاخان’, ‘جانی خیل’, ‘نکه’, ‘وازه خواه’, ‘دیله و خوشامند’, ‘ورممی’, ‘زرغون شهر’, ‘زیروک’, ‘یحیی خیل’, ‘سرحوضه’, ‘یوسف خیل’, ‘سروبی’],
farah: [‘اناردره’, ‘بالابلوک’, ‘بکواه’, ‘پرچمن’, ‘پشت رود’, ‘خاک سفید’, ‘شیب کوه’, ‘فراه’, ‘قلعه کاه’, ‘گلستان’, ‘لاش و جوین’],
helmand: [‘بغران’, ‘دیشو’, ‘ریگ خان نشین’, ‘سنگین’, ‘کجکی’, ‘گرمسیر’, ‘لشکرگاه’, ‘موسی قلعه’, ‘نادعلی’, ‘ناوه بارکزائی’, ‘نوزاد’, ‘نهرسراج’, ‘واشیر’, ‘گرشک’, ‘مرجه’],
nimroz: [‘چغانسور’, ‘چهاربرجک’, ‘خاش رود’, ‘زرنج’, ‘کنگ’],
ghazni: [‘آب بند’, ‘جغتو’, ‘آجرستان’, ‘قره باغ’, ‘گیرو’, ‘اندر’, ‘گیلان’, ‘بهرام شهید’, ‘مالستان’, ‘جاغوری’, ‘مقر’, ‘عمری’, ‘ناور’, ‘ده یک’, ‘ناوه’, ‘رشیدان’, ‘واغز’, ‘زنه خان’, ‘ولی محمد شهید خوگیانی’, ‘غزنی’],
uruzgan: [‘ترینکوت’, ‘چوره’, ‘خاص ارزگان’, ‘دهراوود’, ‘شهید حساس’, ‘گیزاب’],
kapisa: [‘آله سائی’, ‘تگاب’, ‘حصه اول کوهستان’, ‘حصه دوم کوهستان’, ‘کوه بند’, ‘نجراب’],
parwan: [‘بگرام’, ‘جبل السراج’, ‘سالنگ’, ‘سرخ پارسا’, ‘سیدخیل’, ‘شیخ علی’, ‘شینواری’, ‘غوربند’, ‘کوه صافی’],
panjshir: [‘آنابه’, ‘بازارک’, ‘پریان’, ‘خنج’, ‘دره’, ‘روخه’, ‘شتل’, ‘آبشار’],
jowzjan: [‘آقچه’, ‘خانقاه’, ‘خم آب’, ‘خواجه دو کوه’, ‘درزاب’, ‘شبرغان’, ‘فیض آباد’, ‘قرقین’, ‘قوش تپه’, ‘مردیان’, ‘منگجک’],
khost: [‘باک’, ‘تنی’, ‘تیریزائی’, ‘جاجی میدان’, ‘خوست متون’, ‘سپیره’, ‘شمل’, ‘صبری/یعقوبی’, ‘قلندر’, ‘گربز’, ‘مندوزی’, ‘موسی خیل’, ‘نادرشاه کوت’],
kunar: [‘اسد آباد’, ‘سرکاڼی’, ‘برکنر’, ‘شیگل و شلتن’, ‘خاص کنر’, ‘غازی آباد’, ‘مروره’, ‘دانگام’, ‘ناری’, ‘نرنگ’, ‘دره پیچ’, ‘نورگل’, ‘چپه دره’, ‘وټه پور’, ‘څوکی’],
daykundi: [‘آشترلی’, ‘نیلی’, ‘خدیر’, ‘سنگ تخت’, ‘شهرستان’, ‘کجران’, ‘میرامور’, ‘گیزاب’, ‘بندر’]
};
// Update districts based on selected province
function updateDistricts() {
const provinceSelect = document.getElementById(‘filter-province’);
const districtSelect = document.getElementById(‘filter-district’);
const selectedProvince = provinceSelect.value;
// Clear existing options
districtSelect.innerHTML = ‘All Districts’;
if (selectedProvince && districtsData[selectedProvince]) {
districtsData[selectedProvince].forEach(district => {
const option = document.createElement(‘option’);
option.value = district;
option.textContent = district;
districtSelect.appendChild(option);
});
}
}
// Security modal functions
function openSecurityModal(repId) {
document.getElementById(‘security-modal’).classList.remove(‘hidden’);
document.getElementById(‘security-modal’).setAttribute(‘data-rep-id’, repId);
}
function closeSecurityModal() {
document.getElementById(‘security-modal’).classList.add(‘hidden’);
document.getElementById(‘security-form’).reset();
}
function submitSecurityRequest(event) {
event.preventDefault();
const name = document.getElementById(‘user-name’).value;
const phone = document.getElementById(‘user-phone’).value;
const email = document.getElementById(‘user-email’).value;
const reason = document.getElementById(‘user-reason’).value;
const repId = document.getElementById(‘security-modal’).getAttribute(‘data-rep-id’);
// Create message for WhatsApp/Email
const message = `Security Verification Request
Name: ${name}
Phone: ${phone}
Email: ${email}
Representative ID: ${repId}
Reason: ${reason}
I am requesting access to representative information for the above reason. Please verify my identity and provide the requested details.`;
// Show success message
const modal = document.getElementById(‘security-modal’);
modal.innerHTML = `
Request Submitted
Your verification request has been submitted. We will review and contact you within 24-48 hours.
Close
`;
setTimeout(() => {
closeSecurityModal();
location.reload();
}, 3000);
}
function contactWhatsApp() {
const name = document.getElementById(‘user-name’).value || ‘Not provided’;
const phone = document.getElementById(‘user-phone’).value || ‘Not provided’;
const email = document.getElementById(‘user-email’).value || ‘Not provided’;
const reason = document.getElementById(‘user-reason’).value || ‘Not provided’;
const message = `Hello, I need access to representative information.
Name: ${name}
Phone: ${phone}
Email: ${email}
Reason: ${reason}
Please help me with verification process.`;
const whatsappUrl = `https://wa.me/+93123456789?text=${encodeURIComponent(message)}`;
window.open(whatsappUrl, ‘_blank’);
}
function contactEmail() {
const name = document.getElementById(‘user-name’).value || ‘Not provided’;
const phone = document.getElementById(‘user-phone’).value || ‘Not provided’;
const email = document.getElementById(‘user-email’).value || ‘Not provided’;
const reason = document.getElementById(‘user-reason’).value || ‘Not provided’;
const subject = ‘Representative Information Access Request’;
const body = `Hello,
I am requesting access to representative information for verification purposes.
Name: ${name}
Phone: ${phone}
Email: ${email}
Reason: ${reason}
Please help me with the verification process.
Thank you.`;
const emailUrl = `mailto:contact@aypfrs.net?subject=${encodeURIComponent(subject)}&body=${encodeURIComponent(body)}`;
window.open(emailUrl, ‘_blank’);
}
// Map modal functions
function openMapModal() {
document.getElementById(‘map-modal’).classList.remove(‘hidden’);
}
function closeMapModal() {
document.getElementById(‘map-modal’).classList.add(‘hidden’);
}
// Email subscription functions
function openEmailSubscription() {
document.getElementById(’email-subscription-modal’).classList.remove(‘hidden’);
}
function closeEmailSubscription() {
document.getElementById(’email-subscription-modal’).classList.add(‘hidden’);
document.getElementById(’email-subscription-form’).reset();
}
function submitEmailSubscription(event) {
event.preventDefault();
const name = document.getElementById(’email-name’).value;
const email = document.getElementById(’email-address’).value;
const locationType = document.getElementById(’email-location-type’).value;
let locationInfo = ”;
if (locationType === ‘afghanistan’) {
const province = document.getElementById(’email-province’).value;
const city = document.getElementById(’email-city’).value;
locationInfo = `${province}, ${city}, Afghanistan`;
} else if (locationType === ‘diaspora’) {
const country = document.getElementById(’email-country’).value;
const city = document.getElementById(’email-diaspora-city’).value;
const origin = document.getElementById(’email-origin’).value;
locationInfo = `${city}, ${country} (Originally from: ${origin || ‘Not specified’})`;
} else {
const country = document.getElementById(’email-int-country’).value;
const city = document.getElementById(’email-int-city’).value;
locationInfo = `${city}, ${country}`;
}
// Show success message
const modal = document.getElementById(’email-subscription-modal’);
modal.innerHTML = `
Subscription Confirmed!
Thank you ${name}! You’ll receive email alerts when parliamentary sessions are scheduled at ${email}.
Close
`;
setTimeout(() => {
closeEmailSubscription();
location.reload();
}, 3000);
}
function updateEmailLocationFields() {
const locationType = document.getElementById(’email-location-type’).value;
const afghanistanFields = document.getElementById(‘afghanistan-fields’);
const diasporaFields = document.getElementById(‘diaspora-fields’);
const internationalFields = document.getElementById(‘international-fields’);
// Hide all fields first
afghanistanFields.classList.add(‘hidden’);
diasporaFields.classList.add(‘hidden’);
internationalFields.classList.add(‘hidden’);
// Show relevant fields
if (locationType === ‘afghanistan’) {
afghanistanFields.classList.remove(‘hidden’);
} else if (locationType === ‘diaspora’) {
diasporaFields.classList.remove(‘hidden’);
} else if (locationType === ‘international’) {
internationalFields.classList.remove(‘hidden’);
}
}
// AYP Support Functions
function openAYPSupport() {
document.getElementById(‘ayp-support-modal’).classList.remove(‘hidden’);
}
function closeAYPSupport() {
document.getElementById(‘ayp-support-modal’).classList.add(‘hidden’);
document.getElementById(‘ayp-support-form’).reset();
document.getElementById(‘support-form-section’).classList.add(‘hidden’);
document.getElementById(‘support-close-section’).classList.remove(‘hidden’);
}
function showSupportForm() {
document.getElementById(‘support-form-section’).classList.remove(‘hidden’);
document.getElementById(‘support-close-section’).classList.add(‘hidden’);
}
function directWhatsAppSupport() {
const message = `Hello AYP Support Team! I need assistance with an urgent matter. Please help me connect with the right person.
This is a direct request for immediate support through your 24/7 helpline.
Thank you for your service to Afghanistan’s youth and future.`;
const whatsappUrl = `https://wa.me/+93123456789?text=${encodeURIComponent(message)}`;
window.open(whatsappUrl, ‘_blank’);
}
function directEmailSupport() {
const subject = ‘AYP 24/7 Support Request – Immediate Assistance Needed’;
const body = `Dear AYP Support Team,
I am reaching out through your 24/7 support system for immediate assistance.
Please contact me as soon as possible to discuss my situation.
Thank you for your dedication to Afghanistan’s youth and bright future.
Best regards`;
const emailUrl = `mailto:support@aypfrs.net?subject=${encodeURIComponent(subject)}&body=${encodeURIComponent(body)}`;
window.open(emailUrl, ‘_blank’);
}
function updateSupportLocationFields() {
const locationType = document.getElementById(‘support-location-type’).value;
const afghanistanFields = document.getElementById(‘support-afghanistan-fields’);
const diasporaFields = document.getElementById(‘support-diaspora-fields’);
const internationalFields = document.getElementById(‘support-international-fields’);
// Hide all fields first
afghanistanFields.classList.add(‘hidden’);
diasporaFields.classList.add(‘hidden’);
internationalFields.classList.add(‘hidden’);
// Show relevant fields
if (locationType === ‘afghanistan’) {
afghanistanFields.classList.remove(‘hidden’);
} else if (locationType === ‘diaspora’) {
diasporaFields.classList.remove(‘hidden’);
} else if (locationType === ‘international’) {
internationalFields.classList.remove(‘hidden’);
}
}
function submitSupportRequest(event) {
event.preventDefault();
const name = document.getElementById(‘support-name’).value;
const category = document.getElementById(‘support-category’).value;
const urgency = document.getElementById(‘support-urgency’).value;
const preferredContact = document.getElementById(‘support-preferred-contact’).value;
// Show success message
const modal = document.getElementById(‘ayp-support-modal’);
modal.innerHTML = `
Support Request Submitted!
Thank you ${name}! Your ${urgency} priority ${category} request has been received. Our team will contact you via ${preferredContact} based on the urgency level.
${urgency === ’emergency’ ? ‘Emergency: Within 1 hour’ :
urgency === ‘high’ ? ‘High Priority: Within 4 hours’ :
urgency === ‘medium’ ? ‘Medium Priority: Within 24 hours’ :
‘Low Priority: Within 48 hours’}
Close
`;
setTimeout(() => {
closeAYPSupport();
location.reload();
}, 5000);
}
// WhatsApp subscription functions
function openWhatsAppSubscription() {
document.getElementById(‘whatsapp-subscription-modal’).classList.remove(‘hidden’);
}
function closeWhatsAppSubscription() {
document.getElementById(‘whatsapp-subscription-modal’).classList.add(‘hidden’);
document.getElementById(‘whatsapp-subscription-form’).reset();
}
function submitWhatsAppSubscription(event) {
event.preventDefault();
const name = document.getElementById(‘whatsapp-name’).value;
const phone = document.getElementById(‘whatsapp-phone’).value;
const locationType = document.getElementById(‘whatsapp-location-type’).value;
let locationInfo = ”;
if (locationType === ‘afghanistan’) {
const province = document.getElementById(‘whatsapp-province’).value;
const city = document.getElementById(‘whatsapp-city’).value;
locationInfo = `${province}, ${city}, Afghanistan`;
} else if (locationType === ‘diaspora’) {
const country = document.getElementById(‘whatsapp-country’).value;
const city = document.getElementById(‘whatsapp-diaspora-city’).value;
const origin = document.getElementById(‘whatsapp-origin’).value;
locationInfo = `${city}, ${country} (Originally from: ${origin || ‘Not specified’})`;
} else {
const country = document.getElementById(‘whatsapp-int-country’).value;
const city = document.getElementById(‘whatsapp-int-city’).value;
locationInfo = `${city}, ${country}`;
}
// Show success message
const modal = document.getElementById(‘whatsapp-subscription-modal’);
modal.innerHTML = `
WhatsApp Subscription Confirmed!
Thank you ${name}! You’ll receive WhatsApp notifications when parliamentary sessions are scheduled. We’ll contact you at ${phone}.
Close
`;
setTimeout(() => {
closeWhatsAppSubscription();
location.reload();
}, 3000);
}
function updateWhatsAppLocationFields() {
const locationType = document.getElementById(‘whatsapp-location-type’).value;
const afghanistanFields = document.getElementById(‘whatsapp-afghanistan-fields’);
const diasporaFields = document.getElementById(‘whatsapp-diaspora-fields’);
const internationalFields = document.getElementById(‘whatsapp-international-fields’);
// Hide all fields first
afghanistanFields.classList.add(‘hidden’);
diasporaFields.classList.add(‘hidden’);
internationalFields.classList.add(‘hidden’);
// Show relevant fields
if (locationType === ‘afghanistan’) {
afghanistanFields.classList.remove(‘hidden’);
} else if (locationType === ‘diaspora’) {
diasporaFields.classList.remove(‘hidden’);
} else if (locationType === ‘international’) {
internationalFields.classList.remove(‘hidden’);
}
}
// Village Liaison Application functions
function openLiaisonApplication() {
document.getElementById(‘liaison-application-modal’).classList.remove(‘hidden’);
}
function closeLiaisonApplication() {
document.getElementById(‘liaison-application-modal’).classList.add(‘hidden’);
document.getElementById(‘liaison-application-form’).reset();
}
function submitLiaisonApplication(event) {
event.preventDefault();
const name = document.getElementById(‘liaison-name’).value;
const village = document.getElementById(‘liaison-village’).value;
const district = document.getElementById(‘liaison-district’).value;
const phone = document.getElementById(‘liaison-phone’).value;
const email = document.getElementById(‘liaison-email’).value;
// Show success message
const modal = document.getElementById(‘liaison-application-modal’);
modal.innerHTML = `
Application Submitted!
Thank you ${name}! Your Village Liaison application for ${village}, ${district} has been received. We’ll contact you within 7-10 days.
Close
`;
setTimeout(() => {
closeLiaisonApplication();
location.reload();
}, 4000);
}
// Candidate Interest functions
function openCandidateInterest() {
document.getElementById(‘candidate-interest-modal’).classList.remove(‘hidden’);
}
function closeCandidateInterest() {
document.getElementById(‘candidate-interest-modal’).classList.add(‘hidden’);
document.getElementById(‘candidate-interest-form’).reset();
}
function submitCandidateInterest(event) {
event.preventDefault();
const name = document.getElementById(‘candidate-name’).value;
const email = document.getElementById(‘candidate-email’).value;
const district = document.getElementById(‘candidate-district’).value;
const phone = document.getElementById(‘candidate-phone’).value;
// Show success message
const modal = document.getElementById(‘candidate-interest-modal’);
modal.innerHTML = `
Interest Registered!
Thank you ${name}! We’ve registered your interest to run for ${district} District Representative. You’ll be notified when nominations open.
Close
`;
setTimeout(() => {
closeCandidateInterest();
location.reload();
}, 4000);
}
// Search representatives function
function searchRepresentatives() {
const searchTerm = document.getElementById(‘search-rep’).value;
const province = document.getElementById(‘filter-province’).value;
const district = document.getElementById(‘filter-district’).value;
// This would normally filter the results
// For now, show a message
if (searchTerm || province || district) {
const message = `Searching for representatives…
${searchTerm ? `Name/Location: ${searchTerm}` : ”}
${province ? `Province: ${province}` : ”}
${district ? `District: ${district}` : ”}`;
// In a real implementation, this would filter the representative cards
console.log(message);
}
}
// Initialize page
document.addEventListener(‘DOMContentLoaded’, function() {
switchLanguage(‘en’);
});
(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement(‘script’);d.innerHTML=”window.__CF$cv$params={r:’99334e8717381327′,t:’MTc2MTI0NDIzOC4wMDAwMDA=’};var a=document.createElement(‘script’);a.nonce=”;a.src=’/cdn-cgi/challenge-platform/scripts/jsd/main.js’;document.getElementsByTagName(‘head’)[0].appendChild(a);”;b.getElementsByTagName(‘head’)[0].appendChild(d)}}if(document.body){var a=document.createElement(‘iframe’);a.height=1;a.width=1;a.style.position=’absolute’;a.style.top=0;a.style.left=0;a.style.border=’none’;a.style.visibility=’hidden’;document.body.appendChild(a);if(‘loading’!==document.readyState)c();else if(window.addEventListener)document.addEventListener(‘DOMContentLoaded’,c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);’loading’!==document.readyState&&(document.onreadystatechange=e,c())}}}})();