sherman37 commited on
Commit
a415edd
·
verified ·
1 Parent(s): 1ab0308

An intelligent CV builder that crafts professional, modern resumes instantly. Users enter key information — career history, education, skills, and goals — and the AI generates a polished, industry-optimized CV with design options, tone customization, and export features.

Browse files

Core Features:
Personal Info Input Section:
Name, photo, contact info
LinkedIn / portfolio links
Job title and career summary
Experience Section:
Role title, company, start–end dates, achievements
Option to “enhance wording” using AI for professionalism
Education Section:
Qualification, institution, dates, honors
Skills Section:
Hard skills (editable tags)
Soft skills (AI-generated suggestions based on role)
AI Summary Generator:
Generates a professional personal statement in a chosen tone: Formal / Confident / Creative / Executive
Design Templates:
Choose from 5 modern CV templates
Auto-format text and spacing
Download in PDF or DOCX
Customization & Optimization:
AI can tailor CV for a specific job title or sector (e.g., “English Teacher in UAE,” “Marketing Manager,” “Software Developer”)
Option for ATS-friendly formatting
Version Control:
Save multiple versions of CVs (e.g., “Academic,” “Corporate,” “Creative”)
Optional Add-ons:
Cover letter generator
LinkedIn summary generator
Auto-translate CV (English ↔ Arabic)
AI Prompts Used Inside the App:
“Rewrite my job experience in a professional tone highlighting measurable results.”
“Generate a 3-sentence personal summary for a [Job Title] with 10+ years’ experience.”
“Optimize this CV for ATS compatibility and key industry terms.”
“Suggest 5 key skills for a [Role] in [Country/Region].”
Output Options:
PDF
DOCX
Sharable link
Design Style:
Modern, minimalistic interface (white background, accent color in blue or teal)
Clean typography (e.g., Inter, Lato, or Poppins)
Intuitive step-by-step navigation with progress bar
User Flow:
User signs in or continues as guest
Completes guided steps for personal info, experience, and education
AI generates draft CV instantly
User edits text or design
Exports or saves version
Target Users:
Job seekers, teachers, professionals, and students
Particularly optimized for international roles (e.g., UAE, UK, USA)
complete the front and backend to make it a comprehensive downloadable application - embed the necessary ai keys needed to function make it aesthetically appealing using the lates ui and ux methodologies - add industry insights and pay scales leveraged by ai / English and arabic - sign up and sign in using firebase - payment gateway 19 aed for united downloads per account / also only one name can be used per account / do not allow different cv names to be used per account - make it a comprehensive granular appealing app

Files changed (3) hide show
  1. README.md +8 -5
  2. builder.html +842 -0
  3. index.html +434 -18
README.md CHANGED
@@ -1,10 +1,13 @@
1
  ---
2
- title: Resumerocket
3
- emoji: 📈
4
- colorFrom: indigo
5
- colorTo: red
6
  sdk: static
7
  pinned: false
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
1
  ---
2
+ title: ResumeRocket 🚀
3
+ colorFrom: blue
4
+ colorTo: yellow
5
+ emoji: 🐳
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - deepsite-v3
10
  ---
11
 
12
+ # Welcome to your new DeepSite project!
13
+ This project was created with [DeepSite](https://deepsite.hf.co).
builder.html ADDED
@@ -0,0 +1,842 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en" dir="auto">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Resume Builder | ResumeRocket</title>
7
+ <link rel="icon" type="image/x-icon" href="/static/favicon.ico">
8
+ <script src="https://cdn.tailwindcss.com"></script>
9
+ <script src="https://unpkg.com/feather-icons"></script>
10
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
11
+ <script src="https://www.gstatic.com/firebasejs/8.10.0/firebase-app.js"></script>
12
+ <script src="https://www.gstatic.com/firebasejs/8.10.0/firebase-auth.js"></script>
13
+ <script src="https://www.gstatic.com/firebasejs/8.10.0/firebase-firestore.js"></script>
14
+ <link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap" rel="stylesheet">
15
+ <style>
16
+ .rtl { direction: rtl; }
17
+ .language-switch { transition: all 0.3s ease; }
18
+ .gradient-bg { background: linear-gradient(135deg, #00c6fb 0%, #005bea 100%); }
19
+ .card-hover { transition: transform 0.3s ease, box-shadow 0.3s ease; }
20
+ .card-hover:hover { transform: translateY(-5px); box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }
21
+ .progress-bar { transition: width 0.5s ease-in-out; }
22
+ .template-selector input:checked + div { border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.5); }
23
+ .skill-tag { transition: all 0.2s ease; }
24
+ .skill-tag:hover { transform: scale(1.05); }
25
+ .arabic-font { font-family: 'Tahoma', sans-serif; }
26
+ .resume-preview { box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05); }
27
+ .section-collapse { transition: all 0.3s ease; }
28
+ .section-collapse-content { overflow: hidden; transition: max-height 0.3s ease; }
29
+ </style>
30
+ </head>
31
+ <body class="font-sans antialiased bg-gray-100">
32
+ <!-- Language Switch -->
33
+ <div class="fixed top-4 right-4 z-50">
34
+ <button id="languageSwitch" class="language-switch flex items-center gap-2 bg-white px-3 py-2 rounded-full shadow-md text-sm font-medium text-blue-600 hover:bg-blue-50">
35
+ <span id="currentLang">EN</span>
36
+ <i data-feather="globe" class="w-4 h-4"></i>
37
+ </button>
38
+ </div>
39
+
40
+ <!-- Navigation -->
41
+ <nav class="bg-white shadow-sm">
42
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
43
+ <div class="flex justify-between h-16 items-center">
44
+ <div class="flex items-center">
45
+ <div class="flex-shrink-0 flex items-center">
46
+ <i data-feather="zap" class="w-6 h-6 text-blue-600"></i>
47
+ <span class="ml-2 font-bold text-gray-900">ResumeRocket</span>
48
+ </div>
49
+ </div>
50
+ <div class="flex items-center space-x-4">
51
+ <button id="premiumBtn" class="bg-yellow-100 text-yellow-800 px-4 py-2 rounded-md text-sm font-medium flex items-center gap-2">
52
+ <i data-feather="star" class="w-4 h-4"></i>
53
+ <span>Upgrade</span>
54
+ </button>
55
+ <button id="logoutBtn" class="text-gray-500 hover:text-gray-700">
56
+ <i data-feather="log-out" class="w-5 h-5"></i>
57
+ </button>
58
+ </div>
59
+ </div>
60
+ </div>
61
+ </nav>
62
+
63
+ <!-- Main Content -->
64
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8">
65
+ <div class="flex flex-col lg:flex-row gap-8">
66
+ <!-- Resume Builder Form -->
67
+ <div class="lg:w-2/3">
68
+ <div class="bg-white rounded-xl shadow-sm p-6 mb-6">
69
+ <div class="flex justify-between items-center mb-6">
70
+ <h2 class="text-2xl font-bold text-gray-900" id="builderTitle">Build Your Resume</h2>
71
+ <div class="flex items-center gap-2">
72
+ <div class="relative">
73
+ <button id="jobRoleDropdownBtn" class="flex items-center gap-2 bg-gray-100 px-3 py-2 rounded-md text-sm font-medium text-gray-700">
74
+ <span id="selectedJobRole">Select Job Role</span>
75
+ <i data-feather="chevron-down" class="w-4 h-4"></i>
76
+ </button>
77
+ <div id="jobRoleDropdown" class="absolute right-0 mt-2 w-56 bg-white rounded-md shadow-lg z-50 hidden">
78
+ <div class="py-1">
79
+ <button class="job-role-option block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left" data-role="Software Developer">Software Developer</button>
80
+ <button class="job-role-option block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left" data-role="Marketing Manager">Marketing Manager</button>
81
+ <button class="job-role-option block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left" data-role="Teacher/Educator">Teacher/Educator</button>
82
+ <button class="job-role-option block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left" data-role="Finance Professional">Finance Professional</button>
83
+ <button class="job-role-option block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left" data-role="Healthcare Professional">Healthcare Professional</button>
84
+ </div>
85
+ </div>
86
+ </div>
87
+ <button id="aiOptimizeBtn" class="flex items-center gap-2 bg-blue-600 text-white px-3 py-2 rounded-md text-sm font-medium">
88
+ <i data-feather="zap" class="w-4 h-4"></i>
89
+ <span>AI Optimize</span>
90
+ </button>
91
+ </div>
92
+ </div>
93
+
94
+ <div class="mb-8">
95
+ <div class="w-full bg-gray-200 rounded-full h-2.5">
96
+ <div id="progressBar" class="bg-blue-600 h-2.5 rounded-full progress-bar" style="width: 25%"></div>
97
+ </div>
98
+ <div class="flex justify-between mt-2 text-sm text-gray-600">
99
+ <span>25% Complete</span>
100
+ <span>Step 1 of 4</span>
101
+ </div>
102
+ </div>
103
+
104
+ <!-- Personal Info Section -->
105
+ <div class="mb-8">
106
+ <div class="flex justify-between items-center mb-4">
107
+ <h3 class="text-lg font-semibold text-gray-900 flex items-center gap-2">
108
+ <i data-feather="user" class="w-5 h-5 text-blue-600"></i>
109
+ <span id="personalInfoTitle">Personal Information</span>
110
+ </h3>
111
+ <button class="text-blue-600 text-sm font-medium flex items-center gap-1">
112
+ <i data-feather="upload" class="w-4 h-4"></i>
113
+ <span>Upload Photo</span>
114
+ </button>
115
+ </div>
116
+
117
+ <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
118
+ <div>
119
+ <label for="fullName" class="block text-sm font-medium text-gray-700 mb-1" id="fullNameLabel">Full Name</label>
120
+ <input type="text" id="fullName" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
121
+ </div>
122
+ <div>
123
+ <label for="jobTitle" class="block text-sm font-medium text-gray-700 mb-1" id="jobTitleLabel">Job Title</label>
124
+ <input type="text" id="jobTitle" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
125
+ </div>
126
+ <div>
127
+ <label for="email" class="block text-sm font-medium text-gray-700 mb-1" id="emailLabel">Email</label>
128
+ <input type="email" id="email" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
129
+ </div>
130
+ <div>
131
+ <label for="phone" class="block text-sm font-medium text-gray-700 mb-1" id="phoneLabel">Phone</label>
132
+ <input type="tel" id="phone" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
133
+ </div>
134
+ <div>
135
+ <label for="linkedin" class="block text-sm font-medium text-gray-700 mb-1">LinkedIn</label>
136
+ <input type="url" id="linkedin" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="https://linkedin.com/in/yourprofile">
137
+ </div>
138
+ <div>
139
+ <label for="portfolio" class="block text-sm font-medium text-gray-700 mb-1">Portfolio</label>
140
+ <input type="url" id="portfolio" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="https://yourwebsite.com">
141
+ </div>
142
+ </div>
143
+ </div>
144
+
145
+ <!-- Summary Section -->
146
+ <div class="mb-8">
147
+ <div class="flex justify-between items-center mb-4">
148
+ <h3 class="text-lg font-semibold text-gray-900 flex items-center gap-2">
149
+ <i data-feather="file-text" class="w-5 h-5 text-blue-600"></i>
150
+ <span id="summaryTitle">Professional Summary</span>
151
+ </h3>
152
+ <div class="flex gap-2">
153
+ <button id="aiGenerateSummaryBtn" class="flex items-center gap-1 text-sm font-medium text-blue-600">
154
+ <i data-feather="zap" class="w-4 h-4"></i>
155
+ <span>AI Generate</span>
156
+ </button>
157
+ <button id="toneDropdownBtn" class="flex items-center gap-1 text-sm font-medium text-gray-600">
158
+ <span id="selectedTone">Formal</span>
159
+ <i data-feather="chevron-down" class="w-4 h-4"></i>
160
+ </button>
161
+ </div>
162
+ </div>
163
+ <textarea id="professionalSummary" rows="4" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="Briefly describe your professional background, skills, and career goals"></textarea>
164
+ </div>
165
+
166
+ <!-- Experience Section -->
167
+ <div class="mb-8">
168
+ <div class="flex justify-between items-center mb-4">
169
+ <h3 class="text-lg font-semibold text-gray-900 flex items-center gap-2">
170
+ <i data-feather="briefcase" class="w-5 h-5 text-blue-600"></i>
171
+ <span id="experienceTitle">Work Experience</span>
172
+ </h3>
173
+ <button id="addExperienceBtn" class="text-blue-600 text-sm font-medium flex items-center gap-1">
174
+ <i data-feather="plus" class="w-4 h-4"></i>
175
+ <span>Add Experience</span>
176
+ </button>
177
+ </div>
178
+
179
+ <div id="experienceContainer">
180
+ <!-- Experience items will be added here -->
181
+ <div class="experience-item bg-gray-50 p-4 rounded-lg mb-4">
182
+ <div class="flex justify-between">
183
+ <div>
184
+ <input type="text" class="font-medium text-gray-900 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none mb-1" placeholder="Job Title">
185
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm" placeholder="Company Name">
186
+ </div>
187
+ <div class="flex items-center gap-2">
188
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="Start">
189
+ <span>-</span>
190
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="End">
191
+ </div>
192
+ </div>
193
+ <div class="mt-3">
194
+ <textarea rows="3" class="w-full px-2 py-1 border border-gray-200 rounded-md focus:outline-none focus:ring-1 focus:ring-blue-500 text-sm" placeholder="Describe your responsibilities and achievements"></textarea>
195
+ <button class="text-blue-600 text-xs font-medium flex items-center gap-1 mt-1">
196
+ <i data-feather="zap" class="w-3 h-3"></i>
197
+ <span>AI Enhance</span>
198
+ </button>
199
+ </div>
200
+ <button class="text-red-500 text-xs font-medium flex items-center gap-1 mt-2">
201
+ <i data-feather="trash-2" class="w-3 h-3"></i>
202
+ <span>Remove</span>
203
+ </button>
204
+ </div>
205
+ </div>
206
+ </div>
207
+
208
+ <!-- Education Section -->
209
+ <div class="mb-8">
210
+ <div class="flex justify-between items-center mb-4">
211
+ <h3 class="text-lg font-semibold text-gray-900 flex items-center gap-2">
212
+ <i data-feather="book" class="w-5 h-5 text-blue-600"></i>
213
+ <span id="educationTitle">Education</span>
214
+ </h3>
215
+ <button id="addEducationBtn" class="text-blue-600 text-sm font-medium flex items-center gap-1">
216
+ <i data-feather="plus" class="w-4 h-4"></i>
217
+ <span>Add Education</span>
218
+ </button>
219
+ </div>
220
+
221
+ <div id="educationContainer">
222
+ <!-- Education items will be added here -->
223
+ <div class="education-item bg-gray-50 p-4 rounded-lg mb-4">
224
+ <div class="flex justify-between">
225
+ <div>
226
+ <input type="text" class="font-medium text-gray-900 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none mb-1" placeholder="Degree">
227
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm" placeholder="Institution">
228
+ </div>
229
+ <div class="flex items-center gap-2">
230
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="Start">
231
+ <span>-</span>
232
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="End">
233
+ </div>
234
+ </div>
235
+ <button class="text-red-500 text-xs font-medium flex items-center gap-1 mt-2">
236
+ <i data-feather="trash-2" class="w-3 h-3"></i>
237
+ <span>Remove</span>
238
+ </button>
239
+ </div>
240
+ </div>
241
+ </div>
242
+
243
+ <!-- Skills Section -->
244
+ <div class="mb-8">
245
+ <div class="flex justify-between items-center mb-4">
246
+ <h3 class="text-lg font-semibold text-gray-900 flex items-center gap-2">
247
+ <i data-feather="award" class="w-5 h-5 text-blue-600"></i>
248
+ <span id="skillsTitle">Skills</span>
249
+ </h3>
250
+ <button id="aiSuggestSkillsBtn" class="text-blue-600 text-sm font-medium flex items-center gap-1">
251
+ <i data-feather="zap" class="w-4 h-4"></i>
252
+ <span>AI Suggest</span>
253
+ </button>
254
+ </div>
255
+
256
+ <div class="flex flex-wrap gap-2 mb-4" id="skillsContainer">
257
+ <!-- Skills will be added here -->
258
+ <div class="skill-tag bg-blue-100 text-blue-800 px-3 py-1 rounded-full text-sm flex items-center gap-1">
259
+ <span>JavaScript</span>
260
+ <button class="text-blue-600 hover:text-blue-800">
261
+ <i data-feather="x" class="w-3 h-3"></i>
262
+ </button>
263
+ </div>
264
+ <div class="skill-tag bg-blue-100 text-blue-800 px-3 py-1 rounded-full text-sm flex items-center gap-1">
265
+ <span>React</span>
266
+ <button class="text-blue-600 hover:text-blue-800">
267
+ <i data-feather="x" class="w-3 h-3"></i>
268
+ </button>
269
+ </div>
270
+ <button id="addSkillBtn" class="skill-tag bg-gray-200 text-gray-700 px-3 py-1 rounded-full text-sm flex items-center gap-1 hover:bg-gray-300">
271
+ <i data-feather="plus" class="w-3 h-3"></i>
272
+ <span>Add Skill</span>
273
+ </button>
274
+ </div>
275
+
276
+ <div id="addSkillInput" class="hidden">
277
+ <div class="flex gap-2">
278
+ <input type="text" id="newSkillInput" class="flex-1 px-3 py-1 border border-gray-300 rounded-md focus:outline-none focus:ring-1 focus:ring-blue-500 text-sm" placeholder="Type a skill">
279
+ <button id="saveSkillBtn" class="bg-blue-600 text-white px-3 py-1 rounded-md text-sm">Add</button>
280
+ <button id="cancelSkillBtn" class="bg-gray-200 text-gray-700 px-3 py-1 rounded-md text-sm">Cancel</button>
281
+ </div>
282
+ </div>
283
+ </div>
284
+
285
+ <!-- Action Buttons -->
286
+ <div class="flex justify-between pt-4 border-t border-gray-200">
287
+ <button id="prevStepBtn" class="bg-gray-200 text-gray-700 px-6 py-2 rounded-md font-medium hover:bg-gray-300">
288
+ <i data-feather="arrow-left" class="w-4 h-4 mr-2"></i>
289
+ <span id="backBtnText">Back</span>
290
+ </button>
291
+ <button id="nextStepBtn" class="bg-blue-600 text-white px-6 py-2 rounded-md font-medium hover:bg-blue-700">
292
+ <span id="nextBtnText">Next: Choose Template</span>
293
+ <i data-feather="arrow-right" class="w-4 h-4 ml-2"></i>
294
+ </button>
295
+ </div>
296
+ </div>
297
+ </div>
298
+
299
+ <!-- Resume Preview -->
300
+ <div class="lg:w-1/3">
301
+ <div class="sticky top-4">
302
+ <div class="bg-white rounded-xl shadow-sm p-6 mb-6">
303
+ <h3 class="text-lg font-semibold text-gray-900 mb-4 flex items-center gap-2">
304
+ <i data-feather="eye" class="w-5 h-5 text-blue-600"></i>
305
+ <span id="previewTitle">Resume Preview</span>
306
+ </h3>
307
+
308
+ <div class="resume-preview bg-white p-6 rounded-lg border border-gray-200">
309
+ <!-- Preview content will be dynamically updated -->
310
+ <div class="text-center mb-6">
311
+ <div class="w-24 h-24 bg-gray-200 rounded-full mx-auto mb-4 overflow-hidden">
312
+ <img src="http://static.photos/office/200x200/1" alt="Profile" class="w-full h-full object-cover">
313
+ </div>
314
+ <h2 class="text-2xl font-bold text-gray-900" id="previewName">Your Name</h2>
315
+ <p class="text-gray-600" id="previewTitle">Job Title</p>
316
+ </div>
317
+
318
+ <div class="mb-6">
319
+ <h3 class="text-lg font-semibold text-gray-900 border-b border-gray-200 pb-1 mb-3">Contact</h3>
320
+ <div class="grid grid-cols-1 gap-2 text-sm">
321
+ <p id="previewEmail">your.email@example.com</p>
322
+ <p id="previewPhone">+1234567890</p>
323
+ <p id="previewLinkedIn">linkedin.com/in/yourprofile</p>
324
+ <p id="previewPortfolio">yourwebsite.com</p>
325
+ </div>
326
+ </div>
327
+
328
+ <div class="mb-6">
329
+ <h3 class="text-lg font-semibold text-gray-900 border-b border-gray-200 pb-1 mb-3">Summary</h3>
330
+ <p class="text-sm text-gray-700" id="previewSummary">Professional summary will appear here...</p>
331
+ </div>
332
+
333
+ <div class="mb-6">
334
+ <h3 class="text-lg font-semibold text-gray-900 border-b border-gray-200 pb-1 mb-3">Experience</h3>
335
+ <div class="space-y-4">
336
+ <div>
337
+ <div class="flex justify-between">
338
+ <p class="font-medium text-gray-900">Job Title</p>
339
+ <p class="text-sm text-gray-600">2020 - Present</p>
340
+ </div>
341
+ <p class="text-sm text-gray-600 mb-1">Company Name</p>
342
+ <p class="text-sm text-gray-700">Job description and achievements will appear here...</p>
343
+ </div>
344
+ </div>
345
+ </div>
346
+
347
+ <div class="mb-6">
348
+ <h3 class="text-lg font-semibold text-gray-900 border-b border-gray-200 pb-1 mb-3">Education</h3>
349
+ <div class="space-y-4">
350
+ <div>
351
+ <div class="flex justify-between">
352
+ <p class="font-medium text-gray-900">Degree</p>
353
+ <p class="text-sm text-gray-600">2016 - 2020</p>
354
+ </div>
355
+ <p class="text-sm text-gray-600">Institution</p>
356
+ </div>
357
+ </div>
358
+ </div>
359
+
360
+ <div>
361
+ <h3 class="text-lg font-semibold text-gray-900 border-b border-gray-200 pb-1 mb-3">Skills</h3>
362
+ <div class="flex flex-wrap gap-2">
363
+ <span class="bg-gray-100 text-gray-800 px-2 py-1 rounded text-xs">Skill 1</span>
364
+ <span class="bg-gray-100 text-gray-800 px-2 py-1 rounded text-xs">Skill 2</span>
365
+ <span class="bg-gray-100 text-gray-800 px-2 py-1 rounded text-xs">Skill 3</span>
366
+ </div>
367
+ </div>
368
+ </div>
369
+ </div>
370
+
371
+ <div class="bg-white rounded-xl shadow-sm p-6">
372
+ <h3 class="text-lg font-semibold text-gray-900 mb-4 flex items-center gap-2">
373
+ <i data-feather="bar-chart-2" class="w-5 h-5 text-blue-600"></i>
374
+ <span id="insightsTitle">Market Insights</span>
375
+ </h3>
376
+
377
+ <div class="space-y-4">
378
+ <div>
379
+ <h4 class="font-medium text-gray-900 mb-2">Software Developer Salaries (UAE)</h4>
380
+ <div class="bg-gray-100 rounded-lg p-3">
381
+ <div class="flex justify-between text-sm mb-1">
382
+ <span>Entry Level</span>
383
+ <span>12,000 - 18,000 AED/mo</span>
384
+ </div>
385
+ <div class="flex justify-between text-sm mb-1">
386
+ <span>Mid-Level</span>
387
+ <span>18,000 - 30,000 AED/mo</span>
388
+ </div>
389
+ <div class="flex justify-between text-sm">
390
+ <span>Senior</span>
391
+ <span>30,000 - 45,000 AED/mo</span>
392
+ </div>
393
+ </div>
394
+ </div>
395
+
396
+ <div>
397
+ <h4 class="font-medium text-gray-900 mb-2">Top In-Demand Skills</h4>
398
+ <div class="flex flex-wrap gap-2">
399
+ <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs">JavaScript</span>
400
+ <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs">React</span>
401
+ <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs">Node.js</span>
402
+ <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs">AWS</span>
403
+ <span class="bg-blue-100 text-blue-800 px-2 py-1 rounded text-xs">Python</span>
404
+ </div>
405
+ </div>
406
+
407
+ <div>
408
+ <h4 class="font-medium text-gray-900 mb-2">ATS Optimization Score</h4>
409
+ <div class="bg-gray-100 rounded-lg p-3">
410
+ <div class="flex items-center gap-3">
411
+ <div class="w-full bg-gray-200 rounded-full h-2.5">
412
+ <div class="bg-green-600 h-2.5 rounded-full" style="width: 65%"></div>
413
+ </div>
414
+ <span class="text-sm font-medium">65%</span>
415
+ </div>
416
+ <p class="text-xs text-gray-600 mt-2" id="atsFeedback">Add more measurable achievements and industry keywords to improve your score.</p>
417
+ </div>
418
+ </div>
419
+ </div>
420
+ </div>
421
+ </div>
422
+ </div>
423
+ </div>
424
+ </div>
425
+
426
+ <!-- Payment Modal -->
427
+ <div id="paymentModal" class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 hidden">
428
+ <div class="bg-white rounded-xl p-8 w-full max-w-md mx-4">
429
+ <div class="flex justify-between items-center mb-6">
430
+ <h3 class="text-2xl font-bold text-gray-800">Upgrade to Premium</h3>
431
+ <button id="closePaymentModal" class="text-gray-500 hover:text-gray-700">
432
+ <i data-feather="x"></i>
433
+ </button>
434
+ </div>
435
+
436
+ <div class="bg-blue-50 p-4 rounded-lg mb-6">
437
+ <div class="flex items-start gap-3">
438
+ <div class="bg-blue-100 p-2 rounded-full">
439
+ <i data-feather="star" class="w-5 h-5 text-blue-600"></i>
440
+ </div>
441
+ <div>
442
+ <h4 class="font-medium text-gray-900 mb-1">Premium Benefits</h4>
443
+ <ul class="text-sm text-gray-700 space-y-1">
444
+ <li class="flex items-center gap-2"><i data-feather="check" class="w-4 h-4 text-green-500"></i> Unlimited resume downloads</li>
445
+ <li class="flex items-center gap-2"><i data-feather="check" class="w-4 h-4 text-green-500"></i> Advanced AI optimization</li>
446
+ <li class="flex items-center gap-2"><i data-feather="check" class="w-4 h-4 text-green-500"></i> Priority support</li>
447
+ <li class="flex items-center gap-2"><i data-feather="check" class="w-4 h-4 text-green-500"></i> Cover letter generator</li>
448
+ </ul>
449
+ </div>
450
+ </div>
451
+ </div>
452
+
453
+ <div class="space-y-4 mb-6">
454
+ <div class="flex items-center justify-between p-4 border border-gray-200 rounded-lg">
455
+ <div>
456
+ <h4 class="font-medium text-gray-900">Monthly Plan</h4>
457
+ <p class="text-sm text-gray-600">Billed monthly, cancel anytime</p>
458
+ </div>
459
+ <div class="text-right">
460
+ <p class="font-bold text-gray-900">19 AED</p>
461
+ <p class="text-sm text-gray-600">per month</p>
462
+ </div>
463
+ </div>
464
+ </div>
465
+
466
+ <button id="proceedToPayment" class="w-full bg-blue-600 text-white py-3 px-4 rounded-lg hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 font-medium">
467
+ Proceed to Payment
468
+ </button>
469
+
470
+ <p class="text-center text-sm text-gray-500 mt-4">Secure payment powered by Stripe</p>
471
+ </div>
472
+ </div>
473
+
474
+ <script>
475
+ // Firebase Configuration
476
+ const firebaseConfig = {
477
+ apiKey: "AIzaSyDEXAMPLE1234567890abcdefghijklmnopq",
478
+ authDomain: "resumerocket-12345.firebaseapp.com",
479
+ projectId: "resumerocket-12345",
480
+ storageBucket: "resumerocket-12345.appspot.com",
481
+ messagingSenderId: "123456789012",
482
+ appId: "1:123456789012:web:abcdefghijklmnopqrstuv"
483
+ };
484
+
485
+ // Initialize Firebase
486
+ firebase.initializeApp(firebaseConfig);
487
+ const db = firebase.firestore();
488
+
489
+ // Language Toggle
490
+ let currentLanguage = 'en';
491
+ const languageSwitch = document.getElementById('languageSwitch');
492
+ const currentLangDisplay = document.getElementById('currentLang');
493
+
494
+ languageSwitch.addEventListener('click', () => {
495
+ currentLanguage = currentLanguage === 'en' ? 'ar' : 'en';
496
+ currentLangDisplay.textContent = currentLanguage === 'en' ? 'EN' : 'AR';
497
+ document.documentElement.lang = currentLanguage;
498
+ document.documentElement.dir = currentLanguage === 'ar' ? 'rtl' : 'ltr';
499
+
500
+ // Update all translatable elements
501
+ updateLanguage();
502
+ });
503
+
504
+ function updateLanguage() {
505
+ const translations = {
506
+ en: {
507
+ builderTitle: "Build Your Resume",
508
+ personalInfoTitle: "Personal Information",
509
+ fullNameLabel: "Full Name",
510
+ jobTitleLabel: "Job Title",
511
+ emailLabel: "Email",
512
+ phoneLabel: "Phone",
513
+ summaryTitle: "Professional Summary",
514
+ experienceTitle: "Work Experience",
515
+ educationTitle: "Education",
516
+ skillsTitle: "Skills",
517
+ previewTitle: "Resume Preview",
518
+ insightsTitle: "Market Insights",
519
+ backBtnText: "Back",
520
+ nextBtnText: "Next: Choose Template",
521
+ atsFeedback: "Add more measurable achievements and industry keywords to improve your score."
522
+ },
523
+ ar: {
524
+ builderTitle: "أنشئ سيرتك الذاتية",
525
+ personalInfoTitle: "المعلومات الشخصية",
526
+ fullNameLabel: "الاسم الكامل",
527
+ jobTitleLabel: "المسمى الوظيفي",
528
+ emailLabel: "البريد الإلكتروني",
529
+ phoneLabel: "الهاتف",
530
+ summaryTitle: "ملخص مهني",
531
+ experienceTitle: "الخبرة العملية",
532
+ educationTitle: "التعليم",
533
+ skillsTitle: "المهارات",
534
+ previewTitle: "معاينة السيرة الذاتية",
535
+ insightsTitle: "رؤى السوق",
536
+ backBtnText: "السابق",
537
+ nextBtnText: "التالي: اختر نموذجًا",
538
+ atsFeedback: "أضف المزيد من الإنجازات القابلة للقياس والكلمات الرئيسية في المجال لتحسين درجتك."
539
+ }
540
+ };
541
+
542
+ const currentTranslations = translations[currentLanguage];
543
+ for (const [key, value] of Object.entries(currentTranslations)) {
544
+ const element = document.getElementById(key);
545
+ if (element) {
546
+ element.textContent = value;
547
+ if (currentLanguage === 'ar' && !element.classList.contains('arabic-font')) {
548
+ element.classList.add('arabic-font');
549
+ } else if (currentLanguage === 'en' && element.classList.contains('arabic-font')) {
550
+ element.classList.remove('arabic-font');
551
+ }
552
+ }
553
+ }
554
+ }
555
+
556
+ // Experience Section
557
+ const addExperienceBtn = document.getElementById('addExperienceBtn');
558
+ const experienceContainer = document.getElementById('experienceContainer');
559
+
560
+ addExperienceBtn.addEventListener('click', () => {
561
+ const newExperience = document.createElement('div');
562
+ newExperience.className = 'experience-item bg-gray-50 p-4 rounded-lg mb-4';
563
+ newExperience.innerHTML = `
564
+ <div class="flex justify-between">
565
+ <div>
566
+ <input type="text" class="font-medium text-gray-900 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none mb-1" placeholder="Job Title">
567
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm" placeholder="Company Name">
568
+ </div>
569
+ <div class="flex items-center gap-2">
570
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="Start">
571
+ <span>-</span>
572
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="End">
573
+ </div>
574
+ </div>
575
+ <div class="mt-3">
576
+ <textarea rows="3" class="w-full px-2 py-1 border border-gray-200 rounded-md focus:outline-none focus:ring-1 focus:ring-blue-500 text-sm" placeholder="Describe your responsibilities and achievements"></textarea>
577
+ <button class="ai-enhance-btn text-blue-600 text-xs font-medium flex items-center gap-1 mt-1">
578
+ <i data-feather="zap" class="w-3 h-3"></i>
579
+ <span>AI Enhance</span>
580
+ </button>
581
+ </div>
582
+ <button class="remove-experience text-red-500 text-xs font-medium flex items-center gap-1 mt-2">
583
+ <i data-feather="trash-2" class="w-3 h-3"></i>
584
+ <span>Remove</span>
585
+ </button>
586
+ `;
587
+ experienceContainer.appendChild(newExperience);
588
+ feather.replace();
589
+
590
+ // Add event listener to the new remove button
591
+ const removeBtn = newExperience.querySelector('.remove-experience');
592
+ removeBtn.addEventListener('click', () => {
593
+ experienceContainer.removeChild(newExperience);
594
+ });
595
+
596
+ // Add event listener to AI enhance button
597
+ const aiEnhanceBtn = newExperience.querySelector('.ai-enhance-btn');
598
+ aiEnhanceBtn.addEventListener('click', () => {
599
+ const textarea = newExperience.querySelector('textarea');
600
+ textarea.value = "AI-enhanced description with measurable achievements and industry-specific keywords...";
601
+ });
602
+ });
603
+
604
+ // Education Section
605
+ const addEducationBtn = document.getElementById('addEducationBtn');
606
+ const educationContainer = document.getElementById('educationContainer');
607
+
608
+ addEducationBtn.addEventListener('click', () => {
609
+ const newEducation = document.createElement('div');
610
+ newEducation.className = 'education-item bg-gray-50 p-4 rounded-lg mb-4';
611
+ newEducation.innerHTML = `
612
+ <div class="flex justify-between">
613
+ <div>
614
+ <input type="text" class="font-medium text-gray-900 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none mb-1" placeholder="Degree">
615
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm" placeholder="Institution">
616
+ </div>
617
+ <div class="flex items-center gap-2">
618
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="Start">
619
+ <span>-</span>
620
+ <input type="text" class="text-gray-600 bg-transparent border-b border-transparent focus:border-gray-300 focus:outline-none text-sm w-20" placeholder="End">
621
+ </div>
622
+ </div>
623
+ <button class="remove-education text-red-500 text-xs font-medium flex items-center gap-1 mt-2">
624
+ <i data-feather="trash-2" class="w-3 h-3"></i>
625
+ <span>Remove</span>
626
+ </button>
627
+ `;
628
+ educationContainer.appendChild(newEducation);
629
+ feather.replace();
630
+
631
+ // Add event listener to the new remove button
632
+ const removeBtn = newEducation.querySelector('.remove-education');
633
+ removeBtn.addEventListener('click', () => {
634
+ educationContainer.removeChild(newEducation);
635
+ });
636
+ });
637
+
638
+ // Skills Section
639
+ const addSkillBtn = document.getElementById('addSkillBtn');
640
+ const skillsContainer = document.getElementById('skillsContainer');
641
+ const addSkillInput = document.getElementById('addSkillInput');
642
+ const newSkillInput = document.getElementById('newSkillInput');
643
+ const saveSkillBtn = document.getElementById('saveSkillBtn');
644
+ const cancelSkillBtn = document.getElementById('cancelSkillBtn');
645
+ const aiSuggestSkillsBtn = document.getElementById('aiSuggestSkillsBtn');
646
+
647
+ addSkillBtn.addEventListener('click', () => {
648
+ addSkillBtn.classList.add('hidden');
649
+ addSkillInput.classList.remove('hidden');
650
+ newSkillInput.focus();
651
+ });
652
+
653
+ cancelSkillBtn.addEventListener('click', () => {
654
+ addSkillInput.classList.add('hidden');
655
+ addSkillBtn.classList.remove('hidden');
656
+ newSkillInput.value = '';
657
+ });
658
+
659
+ saveSkillBtn.addEventListener('click', () => {
660
+ const skill = newSkillInput.value.trim();
661
+ if (skill) {
662
+ const skillTag = document.createElement('div');
663
+ skillTag.className = 'skill-tag bg-blue-100 text-blue-800 px-3 py-1 rounded-full text-sm flex items-center gap-1';
664
+ skillTag.innerHTML = `
665
+ <span>${skill}</span>
666
+ <button class="remove-skill text-blue-600 hover:text-blue-800">
667
+ <i data-feather="x" class="w-3 h-3"></i>
668
+ </button>
669
+ `;
670
+ skillsContainer.insertBefore(skillTag, addSkillBtn);
671
+ feather.replace();
672
+
673
+ // Add event listener to remove button
674
+ const removeBtn = skillTag.querySelector('.remove-skill');
675
+ removeBtn.addEventListener('click', () => {
676
+ skillsContainer.removeChild(skillTag);
677
+ });
678
+
679
+ newSkillInput.value = '';
680
+ }
681
+ addSkillInput.classList.add('hidden');
682
+ addSkillBtn.classList.remove('hidden');
683
+ });
684
+
685
+ aiSuggestSkillsBtn.addEventListener('click', () => {
686
+ const suggestedSkills = ['JavaScript', 'React', 'Node.js', 'Python', 'CSS', 'HTML', 'Git', 'AWS'];
687
+ suggestedSkills.forEach(skill => {
688
+ if (!Array.from(skillsContainer.querySelectorAll('.skill-tag span')).some(el => el.textContent === skill)) {
689
+ const skillTag = document.createElement('div');
690
+ skillTag.className = 'skill-tag bg-blue-100 text-blue-800 px-3 py-1 rounded-full text-sm flex items-center gap-1';
691
+ skillTag.innerHTML = `
692
+ <span>${skill}</span>
693
+ <button class="remove-skill text-blue-600 hover:text-blue-800">
694
+ <i data-feather="x" class="w-3 h-3"></i>
695
+ </button>
696
+ `;
697
+ skillsContainer.insertBefore(skillTag, addSkillBtn);
698
+
699
+ // Add event listener to remove button
700
+ const removeBtn = skillTag.querySelector('.remove-skill');
701
+ removeBtn.addEventListener('click', () => {
702
+ skillsContainer.removeChild(skillTag);
703
+ });
704
+ }
705
+ });
706
+ feather.replace();
707
+ });
708
+
709
+ // Job Role Dropdown
710
+ const jobRoleDropdownBtn = document.getElementById('jobRoleDropdownBtn');
711
+ const jobRoleDropdown = document.getElementById('jobRoleDropdown');
712
+ const selectedJobRole = document.getElementById('selectedJobRole');
713
+
714
+ jobRoleDropdownBtn.addEventListener('click', () => {
715
+ jobRoleDropdown.classList.toggle('hidden');
716
+ });
717
+
718
+ document.querySelectorAll('.job-role-option').forEach(option => {
719
+ option.addEventListener('click', () => {
720
+ selectedJobRole.textContent = option.getAttribute('data-role');
721
+ jobRoleDropdown.classList.add('hidden');
722
+ });
723
+ });
724
+
725
+ // Tone Dropdown
726
+ const toneDropdownBtn = document.getElementById('toneDropdownBtn');
727
+ const selectedTone = document.getElementById('selectedTone');
728
+ const aiGenerateSummaryBtn = document.getElementById('aiGenerateSummaryBtn');
729
+ const professionalSummary = document.getElementById('professionalSummary');
730
+
731
+ aiGenerateSummaryBtn.addEventListener('click', () => {
732
+ const tones = {
733
+ 'Formal': "Results-driven professional with extensive experience in [field]. Adept at [key skills]. Seeking to leverage expertise in [specific area] to contribute to [company goals].",
734
+ 'Confident': "Seasoned [profession] with a proven track record in [achievements]. Passionate about [industry aspects]. Ready to bring [specific skills] to drive success at [company].",
735
+ 'Creative': "Innovative [profession] with a flair for [creative aspects]. Specializing in [unique skills]. Excited to collaborate with like-minded teams to create [impactful results]."
736
+ };
737
+
738
+ professionalSummary.value = tones[selectedTone.textContent] || tones['Formal'];
739
+ });
740
+
741
+ // Template Selection
742
+ document.querySelectorAll('.template-selector input').forEach(radio => {
743
+ radio.addEventListener('change', () => {
744
+ if (radio.checked) {
745
+ // Update preview styling based on selected template
746
+ const preview = document.querySelector('.resume-preview');
747
+ preview.className = 'resume-preview bg-white p-6 rounded-lg border border-gray-200';
748
+
749
+ if (radio.id === 'template1') {
750
+ // Executive template styling
751
+ } else if (radio.id === 'template2') {
752
+ // Creative template styling
753
+ preview.classList.add('bg-gray-50');
754
+ } else if (radio.id === 'template3') {
755
+ // Technical template styling
756
+ preview.classList.add('bg-gray-100');
757
+ }
758
+ }
759
+ });
760
+ });
761
+
762
+ // Form Input Updates to Preview
763
+ document.getElementById('fullName').addEventListener('input', (e) => {
764
+ document.getElementById('previewName').textContent = e.target.value || 'Your Name';
765
+ });
766
+
767
+ document.getElementById('jobTitle').addEventListener('input', (e) => {
768
+ document.getElementById('previewTitle').textContent = e.target.value || 'Job Title';
769
+ });
770
+
771
+ document.getElementById('email').addEventListener('input', (e) => {
772
+ document.getElementById('previewEmail').textContent = e.target.value || 'your.email@example.com';
773
+ });
774
+
775
+ document.getElementById('phone').addEventListener('input', (e) => {
776
+ document.getElementById('previewPhone').textContent = e.target.value || '+1234567890';
777
+ });
778
+
779
+ document.getElementById('linkedin').addEventListener('input', (e) => {
780
+ document.getElementById('previewLinkedIn').textContent = e.target.value ? e.target.value.replace('https://', '') : 'linkedin.com/in/yourprofile';
781
+ });
782
+
783
+ document.getElementById('portfolio').addEventListener('input', (e) => {
784
+ document.getElementById('previewPortfolio').textContent = e.target.value ? e.target.value.replace('https://', '') : 'yourwebsite.com';
785
+ });
786
+
787
+ document.getElementById('professionalSummary').addEventListener('input', (e) => {
788
+ document.getElementById('previewSummary').textContent = e.target.value || 'Professional summary will appear here...';
789
+ });
790
+
791
+ // Payment Modal
792
+ const premiumBtn = document.getElementById('premiumBtn');
793
+ const paymentModal = document.getElementById('paymentModal');
794
+ const closePaymentModal = document.getElementById('closePaymentModal');
795
+
796
+ premiumBtn.addEventListener('click', () => {
797
+ paymentModal.classList.remove('hidden');
798
+ document.body.style.overflow = 'hidden';
799
+ });
800
+
801
+ closePaymentModal.addEventListener('click', () => {
802
+ paymentModal.classList.add('hidden');
803
+ document.body.style.overflow = 'auto';
804
+ });
805
+
806
+ document.getElementById('proceedToPayment').addEventListener('click', () => {
807
+ alert('Payment processing would be implemented here with Stripe integration');
808
+ paymentModal.classList.add('hidden');
809
+ document.body.style.overflow = 'auto';
810
+ });
811
+
812
+ // Logout
813
+ document.getElementById('logoutBtn').addEventListener('click', () => {
814
+ firebase.auth().signOut().then(() => {
815
+ window.location.href = 'index.html';
816
+ });
817
+ });
818
+
819
+ // Initialize Feather Icons
820
+ document.addEventListener('DOMContentLoaded', () => {
821
+ feather.replace();
822
+
823
+ // Check auth state
824
+ firebase.auth().onAuthStateChanged((user) => {
825
+ if (!user) {
826
+ window.location.href = 'index.html';
827
+ } else {
828
+ // Set user's name if available
829
+ if (user.displayName) {
830
+ document.getElementById('fullName').value = user.displayName;
831
+ document.getElementById('previewName').textContent = user.displayName;
832
+ }
833
+ if (user.email) {
834
+ document.getElementById('email').value = user.email;
835
+ document.getElementById('previewEmail').textContent = user.email;
836
+ }
837
+ }
838
+ });
839
+ });
840
+ </script>
841
+ </body>
842
+ </html>
index.html CHANGED
@@ -1,19 +1,435 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  </html>
 
1
+ <!DOCTYPE html>
2
+ <html lang="en" dir="auto">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>ResumeRocket - AI-Powered CV Builder</title>
7
+ <link rel="icon" type="image/x-icon" href="/static/favicon.ico">
8
+ <script src="https://cdn.tailwindcss.com"></script>
9
+ <script src="https://unpkg.com/feather-icons"></script>
10
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
11
+ <script src="https://www.gstatic.com/firebasejs/8.10.0/firebase-app.js"></script>
12
+ <script src="https://www.gstatic.com/firebasejs/8.10.0/firebase-auth.js"></script>
13
+ <script src="https://cdn.jsdelivr.net/npm/vanta@latest/dist/vanta.net.min.js"></script>
14
+ <link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap" rel="stylesheet">
15
+ <style>
16
+ .rtl { direction: rtl; }
17
+ .language-switch { transition: all 0.3s ease; }
18
+ .gradient-bg { background: linear-gradient(135deg, #00c6fb 0%, #005bea 100%); }
19
+ .card-hover { transition: transform 0.3s ease, box-shadow 0.3s ease; }
20
+ .card-hover:hover { transform: translateY(-5px); box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }
21
+ .progress-bar { transition: width 0.5s ease-in-out; }
22
+ .template-selector input:checked + div { border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.5); }
23
+ .skill-tag { transition: all 0.2s ease; }
24
+ .skill-tag:hover { transform: scale(1.05); }
25
+ .arabic-font { font-family: 'Tahoma', sans-serif; }
26
+ </style>
27
+ </head>
28
+ <body class="font-sans antialiased bg-gray-50" id="vanta-bg">
29
+ <!-- Language Switch -->
30
+ <div class="fixed top-4 right-4 z-50">
31
+ <button id="languageSwitch" class="language-switch flex items-center gap-2 bg-white px-3 py-2 rounded-full shadow-md text-sm font-medium text-blue-600 hover:bg-blue-50">
32
+ <span id="currentLang">EN</span>
33
+ <i data-feather="globe" class="w-4 h-4"></i>
34
+ </button>
35
+ </div>
36
+
37
+ <!-- Auth Modal -->
38
+ <div id="authModal" class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 hidden">
39
+ <div class="bg-white rounded-xl p-8 w-full max-w-md mx-4">
40
+ <div class="flex justify-between items-center mb-6">
41
+ <h3 class="text-2xl font-bold text-gray-800" id="authTitle">Sign In</h3>
42
+ <button id="closeAuthModal" class="text-gray-500 hover:text-gray-700">
43
+ <i data-feather="x"></i>
44
+ </button>
45
+ </div>
46
+ <div id="authTabs" class="flex border-b border-gray-200 mb-6">
47
+ <button class="auth-tab py-2 px-4 font-medium text-sm flex-1 text-center border-b-2 border-transparent" data-tab="signin">Sign In</button>
48
+ <button class="auth-tab py-2 px-4 font-medium text-sm flex-1 text-center border-b-2 border-transparent" data-tab="signup">Sign Up</button>
49
+ </div>
50
+ <form id="authForm" class="space-y-4">
51
+ <div>
52
+ <label for="authEmail" class="block text-sm font-medium text-gray-700 mb-1">Email</label>
53
+ <input type="email" id="authEmail" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" required>
54
+ </div>
55
+ <div>
56
+ <label for="authPassword" class="block text-sm font-medium text-gray-700 mb-1">Password</label>
57
+ <input type="password" id="authPassword" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500" required minlength="6">
58
+ </div>
59
+ <div id="nameField" class="hidden">
60
+ <label for="authName" class="block text-sm font-medium text-gray-700 mb-1">Full Name</label>
61
+ <input type="text" id="authName" class="w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500">
62
+ </div>
63
+ <button type="submit" id="authSubmit" class="w-full bg-blue-600 text-white py-2 px-4 rounded-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 transition">
64
+ Sign In
65
+ </button>
66
+ </form>
67
+ <div class="mt-4 text-center text-sm text-gray-600">
68
+ <button id="forgotPassword" class="text-blue-600 hover:text-blue-800">Forgot password?</button>
69
+ </div>
70
+ </div>
71
+ </div>
72
+
73
+ <!-- Hero Section -->
74
+ <header class="relative overflow-hidden">
75
+ <div class="absolute inset-0 gradient-bg opacity-90"></div>
76
+ <div class="relative max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-24">
77
+ <div class="text-center">
78
+ <h1 class="text-4xl md:text-5xl font-bold text-white mb-4" id="heroTitle">Build Your Perfect Resume in Minutes</h1>
79
+ <p class="text-xl text-blue-100 max-w-3xl mx-auto mb-8" id="heroSubtitle">AI-powered CV builder that crafts professional, optimized resumes for any job in English or Arabic</p>
80
+ <div class="flex flex-col sm:flex-row justify-center gap-4">
81
+ <button id="getStartedBtn" class="bg-white text-blue-600 px-6 py-3 rounded-lg font-semibold hover:bg-blue-50 transition shadow-lg">
82
+ Get Started - It's Free
83
+ </button>
84
+ <button class="bg-white bg-opacity-20 text-white px-6 py-3 rounded-lg font-semibold hover:bg-opacity-30 transition border border-white border-opacity-30 shadow-lg flex items-center gap-2">
85
+ <i data-feather="play-circle" class="w-5 h-5"></i>
86
+ <span>See How It Works</span>
87
+ </button>
88
+ </div>
89
+ </div>
90
+ </div>
91
+ </header>
92
+
93
+ <!-- Features Section -->
94
+ <section class="py-16 bg-white">
95
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
96
+ <div class="text-center mb-16">
97
+ <h2 class="text-3xl font-bold text-gray-900 mb-4" id="featuresTitle">Why ResumeRocket Stands Out</h2>
98
+ <p class="text-lg text-gray-600 max-w-3xl mx-auto" id="featuresSubtitle">Powered by advanced AI to give you the competitive edge in your job search</p>
99
+ </div>
100
+ <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
101
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
102
+ <div class="w-12 h-12 bg-blue-100 rounded-lg flex items-center justify-center mb-4">
103
+ <i data-feather="zap" class="w-6 h-6 text-blue-600"></i>
104
+ </div>
105
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">AI-Powered Enhancements</h3>
106
+ <p class="text-gray-600">Get professional phrasing, measurable achievements, and industry-specific keywords suggested by our AI</p>
107
+ </div>
108
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
109
+ <div class="w-12 h-12 bg-teal-100 rounded-lg flex items-center justify-center mb-4">
110
+ <i data-feather="globe" class="w-6 h-6 text-teal-600"></i>
111
+ </div>
112
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">Dual Language Support</h3>
113
+ <p class="text-gray-600">Create resumes in both English and Arabic with perfect translations for the Middle East job market</p>
114
+ </div>
115
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
116
+ <div class="w-12 h-12 bg-purple-100 rounded-lg flex items-center justify-center mb-4">
117
+ <i data-feather="dollar-sign" class="w-6 h-6 text-purple-600"></i>
118
+ </div>
119
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">Salary Insights</h3>
120
+ <p class="text-gray-600">Get real-time salary data for your role and region to negotiate better offers</p>
121
+ </div>
122
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
123
+ <div class="w-12 h-12 bg-green-100 rounded-lg flex items-center justify-center mb-4">
124
+ <i data-feather="check-circle" class="w-6 h-6 text-green-600"></i>
125
+ </div>
126
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">ATS Optimization</h3>
127
+ <p class="text-gray-600">Our resumes are designed to pass through Applicant Tracking Systems with high scores</p>
128
+ </div>
129
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
130
+ <div class="w-12 h-12 bg-yellow-100 rounded-lg flex items-center justify-center mb-4">
131
+ <i data-feather="file-text" class="w-6 h-6 text-yellow-600"></i>
132
+ </div>
133
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">Smart Templates</h3>
134
+ <p class="text-gray-600">Choose from professionally designed templates that suit your industry and experience level</p>
135
+ </div>
136
+ <div class="card-hover bg-gray-50 p-6 rounded-xl">
137
+ <div class="w-12 h-12 bg-red-100 rounded-lg flex items-center justify-center mb-4">
138
+ <i data-feather="download" class="w-6 h-6 text-red-600"></i>
139
+ </div>
140
+ <h3 class="text-xl font-semibold text-gray-900 mb-2">One-Click Export</h3>
141
+ <p class="text-gray-600">Download in PDF, DOCX or get a shareable link to send to recruiters instantly</p>
142
+ </div>
143
+ </div>
144
+ </div>
145
+ </section>
146
+
147
+ <!-- Templates Preview -->
148
+ <section class="py-16 bg-gray-50">
149
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
150
+ <div class="text-center mb-16">
151
+ <h2 class="text-3xl font-bold text-gray-900 mb-4" id="templatesTitle">Professional Resume Templates</h2>
152
+ <p class="text-lg text-gray-600 max-w-3xl mx-auto" id="templatesSubtitle">Designed to impress recruiters and pass ATS scans</p>
153
+ </div>
154
+ <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
155
+ <div class="template-selector">
156
+ <input type="radio" name="template" id="template1" class="hidden" checked>
157
+ <label for="template1" class="cursor-pointer">
158
+ <div class="card-hover bg-white rounded-xl overflow-hidden shadow-md border-2 border-transparent">
159
+ <div class="h-48 bg-blue-600 flex items-center justify-center">
160
+ <span class="text-white font-bold text-xl">Minimalist</span>
161
+ </div>
162
+ <div class="p-4">
163
+ <h3 class="font-medium text-gray-900 mb-1">Executive</h3>
164
+ <p class="text-sm text-gray-600">Clean and professional for corporate roles</p>
165
+ </div>
166
+ </div>
167
+ </label>
168
+ </div>
169
+ <div class="template-selector">
170
+ <input type="radio" name="template" id="template2" class="hidden">
171
+ <label for="template2" class="cursor-pointer">
172
+ <div class="card-hover bg-white rounded-xl overflow-hidden shadow-md border-2 border-transparent">
173
+ <div class="h-48 bg-teal-500 flex items-center justify-center">
174
+ <span class="text-white font-bold text-xl">Modern</span>
175
+ </div>
176
+ <div class="p-4">
177
+ <h3 class="font-medium text-gray-900 mb-1">Creative</h3>
178
+ <p class="text-sm text-gray-600">For designers and creative professionals</p>
179
+ </div>
180
+ </div>
181
+ </label>
182
+ </div>
183
+ <div class="template-selector">
184
+ <input type="radio" name="template" id="template3" class="hidden">
185
+ <label for="template3" class="cursor-pointer">
186
+ <div class="card-hover bg-white rounded-xl overflow-hidden shadow-md border-2 border-transparent">
187
+ <div class="h-48 bg-gray-800 flex items-center justify-center">
188
+ <span class="text-white font-bold text-xl">Bold</span>
189
+ </div>
190
+ <div class="p-4">
191
+ <h3 class="font-medium text-gray-900 mb-1">Technical</h3>
192
+ <p class="text-sm text-gray-600">For engineers and developers</p>
193
+ </div>
194
+ </div>
195
+ </label>
196
+ </div>
197
+ </div>
198
+ </div>
199
+ </section>
200
+
201
+ <!-- CTA Section -->
202
+ <section class="py-16 gradient-bg">
203
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 text-center">
204
+ <h2 class="text-3xl font-bold text-white mb-6" id="ctaTitle">Ready to Build Your Winning Resume?</h2>
205
+ <p class="text-xl text-blue-100 mb-8 max-w-3xl mx-auto" id="ctaSubtitle">Join thousands who landed interviews at top companies with ResumeRocket</p>
206
+ <div class="flex flex-col sm:flex-row justify-center gap-4">
207
+ <button id="mainGetStartedBtn" class="bg-white text-blue-600 px-8 py-4 rounded-lg font-semibold text-lg hover:bg-blue-50 transition shadow-lg">
208
+ Start Now - It's Free
209
+ </button>
210
+ <button class="bg-white bg-opacity-20 text-white px-8 py-4 rounded-lg font-semibold text-lg hover:bg-opacity-30 transition border border-white border-opacity-30 shadow-lg flex items-center gap-2">
211
+ <i data-feather="dollar-sign" class="w-5 h-5"></i>
212
+ <span>Upgrade to Premium</span>
213
+ </button>
214
+ </div>
215
+ <p class="text-blue-100 mt-6 text-sm" id="pricingNote">Premium unlocks unlimited downloads for just 19 AED/month</p>
216
+ </div>
217
+ </section>
218
+
219
+ <!-- Footer -->
220
+ <footer class="bg-gray-900 text-white py-12">
221
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
222
+ <div class="grid grid-cols-1 md:grid-cols-4 gap-8">
223
+ <div>
224
+ <h3 class="text-lg font-semibold mb-4">ResumeRocket</h3>
225
+ <p class="text-gray-400 text-sm">The smartest way to build resumes that get you hired faster.</p>
226
+ </div>
227
+ <div>
228
+ <h4 class="text-md font-medium mb-4">Product</h4>
229
+ <ul class="space-y-2">
230
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Features</a></li>
231
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Templates</a></li>
232
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Pricing</a></li>
233
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">FAQ</a></li>
234
+ </ul>
235
+ </div>
236
+ <div>
237
+ <h4 class="text-md font-medium mb-4">Company</h4>
238
+ <ul class="space-y-2">
239
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">About Us</a></li>
240
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Careers</a></li>
241
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Privacy Policy</a></li>
242
+ <li><a href="#" class="text-gray-400 hover:text-white text-sm">Terms of Service</a></li>
243
+ </ul>
244
+ </div>
245
+ <div>
246
+ <h4 class="text-md font-medium mb-4">Connect</h4>
247
+ <div class="flex space-x-4 mb-4">
248
+ <a href="#" class="text-gray-400 hover:text-white"><i data-feather="twitter"></i></a>
249
+ <a href="#" class="text-gray-400 hover:text-white"><i data-feather="linkedin"></i></a>
250
+ <a href="#" class="text-gray-400 hover:text-white"><i data-feather="facebook"></i></a>
251
+ <a href="#" class="text-gray-400 hover:text-white"><i data-feather="instagram"></i></a>
252
+ </div>
253
+ <p class="text-gray-400 text-sm">support@resumerocket.com</p>
254
+ </div>
255
+ </div>
256
+ <div class="border-t border-gray-800 mt-8 pt-8 text-center text-gray-400 text-sm">
257
+ <p>&copy; 2023 ResumeRocket. All rights reserved.</p>
258
+ </div>
259
+ </div>
260
+ </footer>
261
+
262
+ <script>
263
+ // Firebase Configuration
264
+ const firebaseConfig = {
265
+ apiKey: "AIzaSyDEXAMPLE1234567890abcdefghijklmnopq",
266
+ authDomain: "resumerocket-12345.firebaseapp.com",
267
+ projectId: "resumerocket-12345",
268
+ storageBucket: "resumerocket-12345.appspot.com",
269
+ messagingSenderId: "123456789012",
270
+ appId: "1:123456789012:web:abcdefghijklmnopqrstuv"
271
+ };
272
+
273
+ // Initialize Firebase
274
+ firebase.initializeApp(firebaseConfig);
275
+
276
+ // Vanta.js Background
277
+ VANTA.NET({
278
+ el: "#vanta-bg",
279
+ color: 0x3b82f6,
280
+ backgroundColor: 0xf8fafc,
281
+ points: 12,
282
+ maxDistance: 20,
283
+ spacing: 15
284
+ });
285
+
286
+ // Language Toggle
287
+ let currentLanguage = 'en';
288
+ const languageSwitch = document.getElementById('languageSwitch');
289
+ const currentLangDisplay = document.getElementById('currentLang');
290
+
291
+ languageSwitch.addEventListener('click', () => {
292
+ currentLanguage = currentLanguage === 'en' ? 'ar' : 'en';
293
+ currentLangDisplay.textContent = currentLanguage === 'en' ? 'EN' : 'AR';
294
+ document.documentElement.lang = currentLanguage;
295
+ document.documentElement.dir = currentLanguage === 'ar' ? 'rtl' : 'ltr';
296
+
297
+ // Update all translatable elements
298
+ updateLanguage();
299
+ });
300
+
301
+ function updateLanguage() {
302
+ const translations = {
303
+ en: {
304
+ heroTitle: "Build Your Perfect Resume in Minutes",
305
+ heroSubtitle: "AI-powered CV builder that crafts professional, optimized resumes for any job in English or Arabic",
306
+ featuresTitle: "Why ResumeRocket Stands Out",
307
+ featuresSubtitle: "Powered by advanced AI to give you the competitive edge in your job search",
308
+ templatesTitle: "Professional Resume Templates",
309
+ templatesSubtitle: "Designed to impress recruiters and pass ATS scans",
310
+ ctaTitle: "Ready to Build Your Winning Resume?",
311
+ ctaSubtitle: "Join thousands who landed interviews at top companies with ResumeRocket",
312
+ pricingNote: "Premium unlocks unlimited downloads for just 19 AED/month"
313
+ },
314
+ ar: {
315
+ heroTitle: "أنشئ سيرتك الذاتية المثالية في دقائق",
316
+ heroSubtitle: "منشئ سير ذاتية مدعوم بالذكاء الاصطناعي يصمم سيرًا ذاتية احترافية ومُحسنة لأي وظيفة باللغتين الإنجليزية والعربية",
317
+ featuresTitle: "لماذا يتميز ResumeRocket",
318
+ featuresSubtitle: "مدعومًا بالذكاء الاصطناعي المتقدم لمنحك ميزة تنافسية في بحثك عن وظيفة",
319
+ templatesTitle: "قوالب سيرة ذاتية احترافية",
320
+ templatesSubtitle: "مصممة لإبهار المسؤولين عن التوظيف واجتياز فحوصات أنظمة تتبع المتقدمين",
321
+ ctaTitle: "هل أنت مستعد لبناء سيرتك الذاتية الفائزة؟",
322
+ ctaSubtitle: "انضم إلى الآلاف الذين حصلوا على مقابلات في كبرى الشركات باستخدام ResumeRocket",
323
+ pricingNote: "الاشتراك المميز يفتح تحميلات غير محدودة مقابل 19 درهمًا فقط شهريًا"
324
+ }
325
+ };
326
+
327
+ const currentTranslations = translations[currentLanguage];
328
+ for (const [key, value] of Object.entries(currentTranslations)) {
329
+ const element = document.getElementById(key);
330
+ if (element) {
331
+ element.textContent = value;
332
+ if (currentLanguage === 'ar' && !element.classList.contains('arabic-font')) {
333
+ element.classList.add('arabic-font');
334
+ } else if (currentLanguage === 'en' && element.classList.contains('arabic-font')) {
335
+ element.classList.remove('arabic-font');
336
+ }
337
+ }
338
+ }
339
+ }
340
+
341
+ // Auth Modal Handling
342
+ const authModal = document.getElementById('authModal');
343
+ const authTitle = document.getElementById('authTitle');
344
+ const authSubmit = document.getElementById('authSubmit');
345
+ const authTabs = document.querySelectorAll('.auth-tab');
346
+ const nameField = document.getElementById('nameField');
347
+ const closeAuthModal = document.getElementById('closeAuthModal');
348
+ const getStartedBtns = document.querySelectorAll('#getStartedBtn, #mainGetStartedBtn');
349
+
350
+ getStartedBtns.forEach(btn => {
351
+ btn.addEventListener('click', () => {
352
+ authModal.classList.remove('hidden');
353
+ document.body.style.overflow = 'hidden';
354
+ });
355
+ });
356
+
357
+ closeAuthModal.addEventListener('click', () => {
358
+ authModal.classList.add('hidden');
359
+ document.body.style.overflow = 'auto';
360
+ });
361
+
362
+ authTabs.forEach(tab => {
363
+ tab.addEventListener('click', () => {
364
+ const tabName = tab.getAttribute('data-tab');
365
+ authTabs.forEach(t => t.classList.remove('border-blue-500', 'text-blue-600'));
366
+ tab.classList.add('border-blue-500', 'text-blue-600');
367
+
368
+ if (tabName === 'signup') {
369
+ authTitle.textContent = currentLanguage === 'en' ? 'Sign Up' : 'تسجيل حساب';
370
+ authSubmit.textContent = currentLanguage === 'en' ? 'Sign Up' : 'تسجيل';
371
+ nameField.classList.remove('hidden');
372
+ } else {
373
+ authTitle.textContent = currentLanguage === 'en' ? 'Sign In' : 'تسجيل الدخول';
374
+ authSubmit.textContent = currentLanguage === 'en' ? 'Sign In' : 'دخول';
375
+ nameField.classList.add('hidden');
376
+ }
377
+ });
378
+ });
379
+
380
+ // Firebase Auth
381
+ const authForm = document.getElementById('authForm');
382
+
383
+ authForm.addEventListener('submit', (e) => {
384
+ e.preventDefault();
385
+ const email = document.getElementById('authEmail').value;
386
+ const password = document.getElementById('authPassword').value;
387
+ const name = document.getElementById('authName').value;
388
+
389
+ const isSignUp = authSubmit.textContent === 'Sign Up' || authSubmit.textContent === 'تسجيل';
390
+
391
+ if (isSignUp) {
392
+ firebase.auth().createUserWithEmailAndPassword(email, password)
393
+ .then((userCredential) => {
394
+ return userCredential.user.updateProfile({
395
+ displayName: name
396
+ });
397
+ })
398
+ .then(() => {
399
+ window.location.href = 'builder.html';
400
+ })
401
+ .catch((error) => {
402
+ alert(error.message);
403
+ });
404
+ } else {
405
+ firebase.auth().signInWithEmailAndPassword(email, password)
406
+ .then(() => {
407
+ window.location.href = 'builder.html';
408
+ })
409
+ .catch((error) => {
410
+ alert(error.message);
411
+ });
412
+ }
413
+ });
414
+
415
+ // Forgot Password
416
+ document.getElementById('forgotPassword').addEventListener('click', () => {
417
+ const email = prompt(currentLanguage === 'en' ? 'Enter your email to reset password:' : 'أدخل بريدك الإلكتروني لإعادة تعيين كلمة المرور:');
418
+ if (email) {
419
+ firebase.auth().sendPasswordResetEmail(email)
420
+ .then(() => {
421
+ alert(currentLanguage === 'en' ? 'Password reset email sent!' : 'تم إرسال رابط إعادة تعيين كلمة المرور!');
422
+ })
423
+ .catch((error) => {
424
+ alert(error.message);
425
+ });
426
+ }
427
+ });
428
+
429
+ // Initialize Feather Icons
430
+ document.addEventListener('DOMContentLoaded', () => {
431
+ feather.replace();
432
+ });
433
+ </script>
434
+ </body>
435
  </html>