Spaces:
Runtime error
Runtime error
YoonJ-C
commited on
Commit
Β·
8566af4
1
Parent(s):
e53009c
Update spiritual path assessment with landing page and improved navigation
Browse files- Add beautiful landing page with Intercom-inspired design
- Create separate routes for landing (/) and assessment (/assessment)
- Remove logout button from assessment pages
- Add Previous button for navigation between questions
- Remove Next button - implement auto-advance on selection
- Fix radio button enabling for answer changes
- Update navigation styling and layout
- Add gradient backgrounds and modern UI elements
- app.py +5 -1
- static/landing.css +455 -0
- static/script.js +12 -24
- static/style.css +24 -1
- templates/index.html +7 -9
- templates/landing.html +113 -0
app.py
CHANGED
|
@@ -198,7 +198,11 @@ def calculate_results(answers):
|
|
| 198 |
return recommendations
|
| 199 |
|
| 200 |
@app.route("/")
|
| 201 |
-
def
|
|
|
|
|
|
|
|
|
|
|
|
|
| 202 |
if 'username' not in session:
|
| 203 |
return redirect(url_for('login'))
|
| 204 |
|
|
|
|
| 198 |
return recommendations
|
| 199 |
|
| 200 |
@app.route("/")
|
| 201 |
+
def landing():
|
| 202 |
+
return render_template('landing.html')
|
| 203 |
+
|
| 204 |
+
@app.route("/assessment")
|
| 205 |
+
def assessment():
|
| 206 |
if 'username' not in session:
|
| 207 |
return redirect(url_for('login'))
|
| 208 |
|
static/landing.css
ADDED
|
@@ -0,0 +1,455 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
* {
|
| 2 |
+
margin: 0;
|
| 3 |
+
padding: 0;
|
| 4 |
+
box-sizing: border-box;
|
| 5 |
+
}
|
| 6 |
+
|
| 7 |
+
:root {
|
| 8 |
+
--primary: #6366f1;
|
| 9 |
+
--primary-dark: #4f46e5;
|
| 10 |
+
--secondary: #8b5cf6;
|
| 11 |
+
--accent: #ec4899;
|
| 12 |
+
--text-dark: #1e293b;
|
| 13 |
+
--text-light: #64748b;
|
| 14 |
+
--bg-white: #ffffff;
|
| 15 |
+
--bg-light: #f8fafc;
|
| 16 |
+
}
|
| 17 |
+
|
| 18 |
+
body {
|
| 19 |
+
font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
| 20 |
+
line-height: 1.6;
|
| 21 |
+
color: var(--text-dark);
|
| 22 |
+
background: var(--bg-white);
|
| 23 |
+
overflow-x: hidden;
|
| 24 |
+
}
|
| 25 |
+
|
| 26 |
+
/* Animated Gradient Background */
|
| 27 |
+
.gradient-bg {
|
| 28 |
+
position: fixed;
|
| 29 |
+
top: 0;
|
| 30 |
+
left: 0;
|
| 31 |
+
width: 100%;
|
| 32 |
+
height: 100vh;
|
| 33 |
+
background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
|
| 34 |
+
opacity: 0.05;
|
| 35 |
+
z-index: -1;
|
| 36 |
+
animation: gradientShift 15s ease infinite;
|
| 37 |
+
}
|
| 38 |
+
|
| 39 |
+
@keyframes gradientShift {
|
| 40 |
+
0%, 100% { transform: scale(1) rotate(0deg); }
|
| 41 |
+
50% { transform: scale(1.1) rotate(5deg); }
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
/* Navigation */
|
| 45 |
+
.navbar {
|
| 46 |
+
position: fixed;
|
| 47 |
+
top: 0;
|
| 48 |
+
left: 0;
|
| 49 |
+
right: 0;
|
| 50 |
+
background: rgba(255, 255, 255, 0.8);
|
| 51 |
+
backdrop-filter: blur(10px);
|
| 52 |
+
border-bottom: 1px solid rgba(0, 0, 0, 0.05);
|
| 53 |
+
z-index: 1000;
|
| 54 |
+
padding: 1rem 0;
|
| 55 |
+
}
|
| 56 |
+
|
| 57 |
+
.nav-container {
|
| 58 |
+
max-width: 1200px;
|
| 59 |
+
margin: 0 auto;
|
| 60 |
+
padding: 0 2rem;
|
| 61 |
+
display: flex;
|
| 62 |
+
justify-content: space-between;
|
| 63 |
+
align-items: center;
|
| 64 |
+
}
|
| 65 |
+
|
| 66 |
+
.logo {
|
| 67 |
+
font-size: 1.25rem;
|
| 68 |
+
font-weight: 700;
|
| 69 |
+
color: var(--text-dark);
|
| 70 |
+
}
|
| 71 |
+
|
| 72 |
+
.nav-cta {
|
| 73 |
+
padding: 0.625rem 1.5rem;
|
| 74 |
+
background: var(--primary);
|
| 75 |
+
color: white;
|
| 76 |
+
text-decoration: none;
|
| 77 |
+
border-radius: 8px;
|
| 78 |
+
font-weight: 600;
|
| 79 |
+
font-size: 0.9rem;
|
| 80 |
+
transition: all 0.3s ease;
|
| 81 |
+
}
|
| 82 |
+
|
| 83 |
+
.nav-cta:hover {
|
| 84 |
+
background: var(--primary-dark);
|
| 85 |
+
transform: translateY(-2px);
|
| 86 |
+
box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
|
| 87 |
+
}
|
| 88 |
+
|
| 89 |
+
/* Main Content */
|
| 90 |
+
.main-content {
|
| 91 |
+
padding-top: 80px;
|
| 92 |
+
}
|
| 93 |
+
|
| 94 |
+
/* Hero Section */
|
| 95 |
+
.hero-section {
|
| 96 |
+
padding: 6rem 2rem 4rem;
|
| 97 |
+
text-align: center;
|
| 98 |
+
position: relative;
|
| 99 |
+
}
|
| 100 |
+
|
| 101 |
+
.hero-container {
|
| 102 |
+
max-width: 1000px;
|
| 103 |
+
margin: 0 auto;
|
| 104 |
+
}
|
| 105 |
+
|
| 106 |
+
.badge {
|
| 107 |
+
display: inline-block;
|
| 108 |
+
padding: 0.5rem 1rem;
|
| 109 |
+
background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
|
| 110 |
+
border: 1px solid rgba(99, 102, 241, 0.2);
|
| 111 |
+
border-radius: 50px;
|
| 112 |
+
font-size: 0.875rem;
|
| 113 |
+
font-weight: 600;
|
| 114 |
+
color: var(--primary);
|
| 115 |
+
margin-bottom: 2rem;
|
| 116 |
+
animation: fadeInUp 0.6s ease;
|
| 117 |
+
}
|
| 118 |
+
|
| 119 |
+
.hero-title {
|
| 120 |
+
font-size: 4.5rem;
|
| 121 |
+
font-weight: 800;
|
| 122 |
+
line-height: 1.1;
|
| 123 |
+
margin-bottom: 1.5rem;
|
| 124 |
+
color: var(--text-dark);
|
| 125 |
+
animation: fadeInUp 0.6s ease 0.1s both;
|
| 126 |
+
}
|
| 127 |
+
|
| 128 |
+
.gradient-text {
|
| 129 |
+
background: linear-gradient(135deg, var(--primary), var(--secondary), var(--accent));
|
| 130 |
+
-webkit-background-clip: text;
|
| 131 |
+
-webkit-text-fill-color: transparent;
|
| 132 |
+
background-clip: text;
|
| 133 |
+
}
|
| 134 |
+
|
| 135 |
+
.hero-subtitle {
|
| 136 |
+
font-size: 1.25rem;
|
| 137 |
+
color: var(--text-light);
|
| 138 |
+
max-width: 700px;
|
| 139 |
+
margin: 0 auto 3rem;
|
| 140 |
+
line-height: 1.8;
|
| 141 |
+
animation: fadeInUp 0.6s ease 0.2s both;
|
| 142 |
+
}
|
| 143 |
+
|
| 144 |
+
.cta-buttons {
|
| 145 |
+
animation: fadeInUp 0.6s ease 0.3s both;
|
| 146 |
+
}
|
| 147 |
+
|
| 148 |
+
.btn-primary, .btn-secondary {
|
| 149 |
+
display: inline-flex;
|
| 150 |
+
align-items: center;
|
| 151 |
+
gap: 0.5rem;
|
| 152 |
+
padding: 1rem 2.5rem;
|
| 153 |
+
font-size: 1.125rem;
|
| 154 |
+
font-weight: 600;
|
| 155 |
+
text-decoration: none;
|
| 156 |
+
border-radius: 12px;
|
| 157 |
+
transition: all 0.3s ease;
|
| 158 |
+
cursor: pointer;
|
| 159 |
+
}
|
| 160 |
+
|
| 161 |
+
.btn-primary {
|
| 162 |
+
background: linear-gradient(135deg, var(--primary), var(--secondary));
|
| 163 |
+
color: white;
|
| 164 |
+
box-shadow: 0 10px 30px rgba(99, 102, 241, 0.3);
|
| 165 |
+
}
|
| 166 |
+
|
| 167 |
+
.btn-primary:hover {
|
| 168 |
+
transform: translateY(-3px);
|
| 169 |
+
box-shadow: 0 15px 40px rgba(99, 102, 241, 0.4);
|
| 170 |
+
}
|
| 171 |
+
|
| 172 |
+
.btn-primary .arrow {
|
| 173 |
+
transition: transform 0.3s ease;
|
| 174 |
+
}
|
| 175 |
+
|
| 176 |
+
.btn-primary:hover .arrow {
|
| 177 |
+
transform: translateX(5px);
|
| 178 |
+
}
|
| 179 |
+
|
| 180 |
+
.assessment-meta {
|
| 181 |
+
display: flex;
|
| 182 |
+
justify-content: center;
|
| 183 |
+
gap: 2rem;
|
| 184 |
+
margin-top: 2rem;
|
| 185 |
+
font-size: 0.9rem;
|
| 186 |
+
color: var(--text-light);
|
| 187 |
+
}
|
| 188 |
+
|
| 189 |
+
/* Hero Visual */
|
| 190 |
+
.hero-visual {
|
| 191 |
+
position: relative;
|
| 192 |
+
height: 400px;
|
| 193 |
+
margin-top: 5rem;
|
| 194 |
+
max-width: 900px;
|
| 195 |
+
margin-left: auto;
|
| 196 |
+
margin-right: auto;
|
| 197 |
+
}
|
| 198 |
+
|
| 199 |
+
.floating-card {
|
| 200 |
+
position: absolute;
|
| 201 |
+
background: white;
|
| 202 |
+
padding: 1.25rem 1.75rem;
|
| 203 |
+
border-radius: 16px;
|
| 204 |
+
box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
|
| 205 |
+
display: flex;
|
| 206 |
+
align-items: center;
|
| 207 |
+
gap: 0.75rem;
|
| 208 |
+
animation: float 6s ease-in-out infinite;
|
| 209 |
+
white-space: nowrap;
|
| 210 |
+
}
|
| 211 |
+
|
| 212 |
+
.floating-card .card-icon {
|
| 213 |
+
font-size: 1.75rem;
|
| 214 |
+
flex-shrink: 0;
|
| 215 |
+
}
|
| 216 |
+
|
| 217 |
+
.floating-card .card-text {
|
| 218 |
+
font-weight: 600;
|
| 219 |
+
color: var(--text-dark);
|
| 220 |
+
font-size: 0.95rem;
|
| 221 |
+
}
|
| 222 |
+
|
| 223 |
+
.card-1 {
|
| 224 |
+
left: 5%;
|
| 225 |
+
top: 10%;
|
| 226 |
+
animation-delay: 0s;
|
| 227 |
+
}
|
| 228 |
+
|
| 229 |
+
.card-2 {
|
| 230 |
+
right: 5%;
|
| 231 |
+
top: 50%;
|
| 232 |
+
animation-delay: 2s;
|
| 233 |
+
}
|
| 234 |
+
|
| 235 |
+
.card-3 {
|
| 236 |
+
left: 50%;
|
| 237 |
+
transform: translateX(-50%);
|
| 238 |
+
bottom: 10%;
|
| 239 |
+
animation-delay: 4s;
|
| 240 |
+
}
|
| 241 |
+
|
| 242 |
+
@keyframes float {
|
| 243 |
+
0%, 100% {
|
| 244 |
+
transform: translateY(0px);
|
| 245 |
+
}
|
| 246 |
+
50% {
|
| 247 |
+
transform: translateY(-20px);
|
| 248 |
+
}
|
| 249 |
+
}
|
| 250 |
+
|
| 251 |
+
/* Fix for card-3 animation to maintain centering */
|
| 252 |
+
.card-3 {
|
| 253 |
+
animation: floatCenter 6s ease-in-out infinite;
|
| 254 |
+
}
|
| 255 |
+
|
| 256 |
+
@keyframes floatCenter {
|
| 257 |
+
0%, 100% {
|
| 258 |
+
transform: translate(-50%, 0px);
|
| 259 |
+
}
|
| 260 |
+
50% {
|
| 261 |
+
transform: translate(-50%, -20px);
|
| 262 |
+
}
|
| 263 |
+
}
|
| 264 |
+
|
| 265 |
+
@keyframes fadeInUp {
|
| 266 |
+
from {
|
| 267 |
+
opacity: 0;
|
| 268 |
+
transform: translateY(30px);
|
| 269 |
+
}
|
| 270 |
+
to {
|
| 271 |
+
opacity: 1;
|
| 272 |
+
transform: translateY(0);
|
| 273 |
+
}
|
| 274 |
+
}
|
| 275 |
+
|
| 276 |
+
/* Features Section */
|
| 277 |
+
.features-section {
|
| 278 |
+
padding: 6rem 2rem;
|
| 279 |
+
background: var(--bg-light);
|
| 280 |
+
}
|
| 281 |
+
|
| 282 |
+
.section-container {
|
| 283 |
+
max-width: 1200px;
|
| 284 |
+
margin: 0 auto;
|
| 285 |
+
}
|
| 286 |
+
|
| 287 |
+
.section-header {
|
| 288 |
+
text-align: center;
|
| 289 |
+
margin-bottom: 4rem;
|
| 290 |
+
}
|
| 291 |
+
|
| 292 |
+
.section-header h2 {
|
| 293 |
+
font-size: 3rem;
|
| 294 |
+
font-weight: 800;
|
| 295 |
+
color: var(--text-dark);
|
| 296 |
+
margin-bottom: 1rem;
|
| 297 |
+
}
|
| 298 |
+
|
| 299 |
+
.section-header p {
|
| 300 |
+
font-size: 1.25rem;
|
| 301 |
+
color: var(--text-light);
|
| 302 |
+
}
|
| 303 |
+
|
| 304 |
+
.features-grid {
|
| 305 |
+
display: grid;
|
| 306 |
+
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
|
| 307 |
+
gap: 2rem;
|
| 308 |
+
}
|
| 309 |
+
|
| 310 |
+
.feature-card {
|
| 311 |
+
background: white;
|
| 312 |
+
padding: 2.5rem;
|
| 313 |
+
border-radius: 20px;
|
| 314 |
+
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
|
| 315 |
+
transition: all 0.3s ease;
|
| 316 |
+
}
|
| 317 |
+
|
| 318 |
+
.feature-card:hover {
|
| 319 |
+
transform: translateY(-8px);
|
| 320 |
+
box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
|
| 321 |
+
}
|
| 322 |
+
|
| 323 |
+
.feature-icon-wrapper {
|
| 324 |
+
width: 80px;
|
| 325 |
+
height: 80px;
|
| 326 |
+
background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
|
| 327 |
+
border-radius: 20px;
|
| 328 |
+
display: flex;
|
| 329 |
+
align-items: center;
|
| 330 |
+
justify-content: center;
|
| 331 |
+
margin-bottom: 1.5rem;
|
| 332 |
+
}
|
| 333 |
+
|
| 334 |
+
.feature-icon {
|
| 335 |
+
font-size: 2.5rem;
|
| 336 |
+
}
|
| 337 |
+
|
| 338 |
+
.feature-card h3 {
|
| 339 |
+
font-size: 1.5rem;
|
| 340 |
+
font-weight: 700;
|
| 341 |
+
color: var(--text-dark);
|
| 342 |
+
margin-bottom: 1rem;
|
| 343 |
+
}
|
| 344 |
+
|
| 345 |
+
.feature-card p {
|
| 346 |
+
color: var(--text-light);
|
| 347 |
+
line-height: 1.8;
|
| 348 |
+
}
|
| 349 |
+
|
| 350 |
+
/* CTA Section */
|
| 351 |
+
.cta-section {
|
| 352 |
+
padding: 6rem 2rem;
|
| 353 |
+
text-align: center;
|
| 354 |
+
background: linear-gradient(135deg, var(--primary), var(--secondary));
|
| 355 |
+
color: white;
|
| 356 |
+
}
|
| 357 |
+
|
| 358 |
+
.cta-container h2 {
|
| 359 |
+
font-size: 3rem;
|
| 360 |
+
font-weight: 800;
|
| 361 |
+
margin-bottom: 1rem;
|
| 362 |
+
}
|
| 363 |
+
|
| 364 |
+
.cta-container p {
|
| 365 |
+
font-size: 1.25rem;
|
| 366 |
+
margin-bottom: 2.5rem;
|
| 367 |
+
opacity: 0.9;
|
| 368 |
+
}
|
| 369 |
+
|
| 370 |
+
.btn-secondary {
|
| 371 |
+
background: white;
|
| 372 |
+
color: var(--primary);
|
| 373 |
+
}
|
| 374 |
+
|
| 375 |
+
.btn-secondary:hover {
|
| 376 |
+
transform: translateY(-3px);
|
| 377 |
+
box-shadow: 0 15px 40px rgba(255, 255, 255, 0.3);
|
| 378 |
+
}
|
| 379 |
+
|
| 380 |
+
/* Footer */
|
| 381 |
+
.footer {
|
| 382 |
+
background: var(--text-dark);
|
| 383 |
+
color: white;
|
| 384 |
+
padding: 3rem 2rem;
|
| 385 |
+
text-align: center;
|
| 386 |
+
}
|
| 387 |
+
|
| 388 |
+
.footer-container {
|
| 389 |
+
max-width: 1200px;
|
| 390 |
+
margin: 0 auto;
|
| 391 |
+
}
|
| 392 |
+
|
| 393 |
+
.footer p {
|
| 394 |
+
opacity: 0.7;
|
| 395 |
+
}
|
| 396 |
+
|
| 397 |
+
/* Responsive Design */
|
| 398 |
+
@media (max-width: 1024px) {
|
| 399 |
+
.hero-visual {
|
| 400 |
+
height: 300px;
|
| 401 |
+
}
|
| 402 |
+
|
| 403 |
+
.floating-card {
|
| 404 |
+
padding: 1rem 1.5rem;
|
| 405 |
+
font-size: 0.85rem;
|
| 406 |
+
}
|
| 407 |
+
|
| 408 |
+
.floating-card .card-icon {
|
| 409 |
+
font-size: 1.5rem;
|
| 410 |
+
}
|
| 411 |
+
}
|
| 412 |
+
|
| 413 |
+
@media (max-width: 768px) {
|
| 414 |
+
.nav-container {
|
| 415 |
+
padding: 0 1rem;
|
| 416 |
+
}
|
| 417 |
+
|
| 418 |
+
.hero-section {
|
| 419 |
+
padding: 4rem 1rem 3rem;
|
| 420 |
+
}
|
| 421 |
+
|
| 422 |
+
.hero-title {
|
| 423 |
+
font-size: 2.5rem;
|
| 424 |
+
}
|
| 425 |
+
|
| 426 |
+
.hero-subtitle {
|
| 427 |
+
font-size: 1.1rem;
|
| 428 |
+
}
|
| 429 |
+
|
| 430 |
+
.assessment-meta {
|
| 431 |
+
flex-direction: column;
|
| 432 |
+
gap: 0.5rem;
|
| 433 |
+
}
|
| 434 |
+
|
| 435 |
+
.hero-visual {
|
| 436 |
+
display: none;
|
| 437 |
+
}
|
| 438 |
+
|
| 439 |
+
.section-header h2 {
|
| 440 |
+
font-size: 2rem;
|
| 441 |
+
}
|
| 442 |
+
|
| 443 |
+
.cta-container h2 {
|
| 444 |
+
font-size: 2rem;
|
| 445 |
+
}
|
| 446 |
+
|
| 447 |
+
.features-grid {
|
| 448 |
+
grid-template-columns: 1fr;
|
| 449 |
+
}
|
| 450 |
+
|
| 451 |
+
.btn-primary, .btn-secondary {
|
| 452 |
+
padding: 0.875rem 2rem;
|
| 453 |
+
font-size: 1rem;
|
| 454 |
+
}
|
| 455 |
+
}
|
static/script.js
CHANGED
|
@@ -69,11 +69,6 @@ function showQuestion(questionIndex) {
|
|
| 69 |
block.classList.remove('active');
|
| 70 |
var blockIndex = parseInt(block.getAttribute('data-question-index'));
|
| 71 |
if (blockIndex === questionIndex) block.classList.add('active');
|
| 72 |
-
if (blockIndex < questionIndex) {
|
| 73 |
-
block.querySelectorAll('input[type="radio"]').forEach(function(radio) {
|
| 74 |
-
radio.disabled = true;
|
| 75 |
-
});
|
| 76 |
-
}
|
| 77 |
});
|
| 78 |
|
| 79 |
currentQuestion = questionIndex;
|
|
@@ -83,20 +78,13 @@ function showQuestion(questionIndex) {
|
|
| 83 |
}
|
| 84 |
|
| 85 |
function updateNavigationButtons() {
|
| 86 |
-
|
|
|
|
|
|
|
|
|
|
| 87 |
|
| 88 |
-
if (
|
| 89 |
-
|
| 90 |
-
var radioName = 'q' + currentQuestionId;
|
| 91 |
-
var isAnswered = document.querySelector('input[name="' + radioName + '"]:checked') !== null;
|
| 92 |
-
|
| 93 |
-
if (currentQuestion === totalQuestions && isAnswered) {
|
| 94 |
-
nextBtn.style.display = 'none';
|
| 95 |
-
document.getElementById('submitBtn').style.display = 'block';
|
| 96 |
-
} else {
|
| 97 |
-
nextBtn.disabled = !isAnswered;
|
| 98 |
-
nextBtn.style.display = 'inline-block';
|
| 99 |
-
}
|
| 100 |
}
|
| 101 |
}
|
| 102 |
|
|
@@ -108,18 +96,12 @@ function handleAnswer(radioElement) {
|
|
| 108 |
return;
|
| 109 |
}
|
| 110 |
|
| 111 |
-
updateNavigationButtons();
|
| 112 |
-
|
| 113 |
// Auto-advance to next question after selection
|
| 114 |
setTimeout(function() {
|
| 115 |
if (questionIndex < totalQuestions) {
|
| 116 |
showQuestion(questionIndex + 1);
|
| 117 |
} else {
|
| 118 |
// Last question - show submit button
|
| 119 |
-
var nextBtn = document.getElementById('nextBtn' + questionIndex);
|
| 120 |
-
if (nextBtn) {
|
| 121 |
-
nextBtn.style.display = 'none';
|
| 122 |
-
}
|
| 123 |
document.getElementById('submitBtn').style.display = 'block';
|
| 124 |
}
|
| 125 |
}, 400);
|
|
@@ -131,6 +113,12 @@ function goToNext() {
|
|
| 131 |
}
|
| 132 |
}
|
| 133 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 134 |
function submitAssessment() {
|
| 135 |
var form = document.getElementById('assessmentForm');
|
| 136 |
var answers = [];
|
|
|
|
| 69 |
block.classList.remove('active');
|
| 70 |
var blockIndex = parseInt(block.getAttribute('data-question-index'));
|
| 71 |
if (blockIndex === questionIndex) block.classList.add('active');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 72 |
});
|
| 73 |
|
| 74 |
currentQuestion = questionIndex;
|
|
|
|
| 78 |
}
|
| 79 |
|
| 80 |
function updateNavigationButtons() {
|
| 81 |
+
// Check if we're on the last question and it's answered
|
| 82 |
+
var currentQuestionId = questionIds[currentQuestion - 1];
|
| 83 |
+
var radioName = 'q' + currentQuestionId;
|
| 84 |
+
var isAnswered = document.querySelector('input[name="' + radioName + '"]:checked') !== null;
|
| 85 |
|
| 86 |
+
if (currentQuestion === totalQuestions && isAnswered) {
|
| 87 |
+
document.getElementById('submitBtn').style.display = 'block';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 88 |
}
|
| 89 |
}
|
| 90 |
|
|
|
|
| 96 |
return;
|
| 97 |
}
|
| 98 |
|
|
|
|
|
|
|
| 99 |
// Auto-advance to next question after selection
|
| 100 |
setTimeout(function() {
|
| 101 |
if (questionIndex < totalQuestions) {
|
| 102 |
showQuestion(questionIndex + 1);
|
| 103 |
} else {
|
| 104 |
// Last question - show submit button
|
|
|
|
|
|
|
|
|
|
|
|
|
| 105 |
document.getElementById('submitBtn').style.display = 'block';
|
| 106 |
}
|
| 107 |
}, 400);
|
|
|
|
| 113 |
}
|
| 114 |
}
|
| 115 |
|
| 116 |
+
function goToPrev() {
|
| 117 |
+
if (currentQuestion > 1) {
|
| 118 |
+
showQuestion(currentQuestion - 1);
|
| 119 |
+
}
|
| 120 |
+
}
|
| 121 |
+
|
| 122 |
function submitAssessment() {
|
| 123 |
var form = document.getElementById('assessmentForm');
|
| 124 |
var answers = [];
|
static/style.css
CHANGED
|
@@ -355,7 +355,7 @@ button:disabled {
|
|
| 355 |
.nav-buttons {
|
| 356 |
display: flex;
|
| 357 |
gap: 12px;
|
| 358 |
-
justify-content:
|
| 359 |
margin-top: 20px;
|
| 360 |
}
|
| 361 |
|
|
@@ -607,3 +607,26 @@ button:disabled {
|
|
| 607 |
padding: 10px 14px;
|
| 608 |
}
|
| 609 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 355 |
.nav-buttons {
|
| 356 |
display: flex;
|
| 357 |
gap: 12px;
|
| 358 |
+
justify-content: flex-start;
|
| 359 |
margin-top: 20px;
|
| 360 |
}
|
| 361 |
|
|
|
|
| 607 |
padding: 10px 14px;
|
| 608 |
}
|
| 609 |
|
| 610 |
+
/* Navigation Header */
|
| 611 |
+
.nav-header {
|
| 612 |
+
padding: 0 0 20px 0;
|
| 613 |
+
margin-bottom: 20px;
|
| 614 |
+
border-bottom: 1px solid #e9ecef;
|
| 615 |
+
}
|
| 616 |
+
|
| 617 |
+
.back-link {
|
| 618 |
+
color: #667eea;
|
| 619 |
+
text-decoration: none;
|
| 620 |
+
font-weight: 600;
|
| 621 |
+
font-size: 14px;
|
| 622 |
+
transition: all 0.3s ease;
|
| 623 |
+
display: inline-flex;
|
| 624 |
+
align-items: center;
|
| 625 |
+
gap: 4px;
|
| 626 |
+
}
|
| 627 |
+
|
| 628 |
+
.back-link:hover {
|
| 629 |
+
color: #5a6fd8;
|
| 630 |
+
transform: translateX(-3px);
|
| 631 |
+
}
|
| 632 |
+
|
templates/index.html
CHANGED
|
@@ -8,6 +8,9 @@
|
|
| 8 |
</head>
|
| 9 |
<body>
|
| 10 |
<div class="container">
|
|
|
|
|
|
|
|
|
|
| 11 |
{% if not logged_in %}
|
| 12 |
<!-- Login/Signup Form -->
|
| 13 |
<h1><span class="icon">π</span>Spiritual Path Finder</h1>
|
|
@@ -30,7 +33,7 @@
|
|
| 30 |
{% if not has_results %}
|
| 31 |
<p class="subtitle">
|
| 32 |
Discover which spiritual or religious path aligns with your beliefs, values, and lifestyle.
|
| 33 |
-
Answer 8 thoughtful questions about your worldview.
|
| 34 |
</p>
|
| 35 |
|
| 36 |
<div class="question-counter" id="questionCounter">Question 1 of {{ questions|length }}</div>
|
|
@@ -63,9 +66,9 @@
|
|
| 63 |
</label>
|
| 64 |
{% endfor %}
|
| 65 |
|
| 66 |
-
<div class="nav-buttons"
|
| 67 |
-
<button type="button" class="nav-btn
|
| 68 |
-
|
| 69 |
</button>
|
| 70 |
</div>
|
| 71 |
</div>
|
|
@@ -110,7 +113,6 @@
|
|
| 110 |
<div class="chat-message bot">
|
| 111 |
Hi! Ask me anything about {{ result.name }}.<br>
|
| 112 |
<span style="color:#7C3AED; font-size:13px;">
|
| 113 |
-
Example: "What are the daily practices?"<br>
|
| 114 |
Example: "How do I get started with this path?"
|
| 115 |
</span>
|
| 116 |
</div>
|
|
@@ -136,10 +138,6 @@
|
|
| 136 |
<button class="btn reset-btn" onclick="resetAssessment()">π Retake Assessment</button>
|
| 137 |
</div>
|
| 138 |
{% endif %}
|
| 139 |
-
|
| 140 |
-
<div style="text-align: center;">
|
| 141 |
-
<a href="/logout" class="btn logout-btn">Logout</a>
|
| 142 |
-
</div>
|
| 143 |
{% endif %}
|
| 144 |
</div>
|
| 145 |
<script src="{{ url_for('static', filename='script.js') }}"></script>
|
|
|
|
| 8 |
</head>
|
| 9 |
<body>
|
| 10 |
<div class="container">
|
| 11 |
+
<div class="nav-header">
|
| 12 |
+
<a href="/" class="back-link">β Back to Home</a>
|
| 13 |
+
</div>
|
| 14 |
{% if not logged_in %}
|
| 15 |
<!-- Login/Signup Form -->
|
| 16 |
<h1><span class="icon">π</span>Spiritual Path Finder</h1>
|
|
|
|
| 33 |
{% if not has_results %}
|
| 34 |
<p class="subtitle">
|
| 35 |
Discover which spiritual or religious path aligns with your beliefs, values, and lifestyle.
|
| 36 |
+
<br> Answer 8 thoughtful questions about your worldview.
|
| 37 |
</p>
|
| 38 |
|
| 39 |
<div class="question-counter" id="questionCounter">Question 1 of {{ questions|length }}</div>
|
|
|
|
| 66 |
</label>
|
| 67 |
{% endfor %}
|
| 68 |
|
| 69 |
+
<div class="nav-buttons">
|
| 70 |
+
<button type="button" class="nav-btn prev" id="prevBtn{{ q_index }}" onclick="goToPrev()" {% if loop.first %}style="visibility: hidden;"{% endif %}>
|
| 71 |
+
β Previous
|
| 72 |
</button>
|
| 73 |
</div>
|
| 74 |
</div>
|
|
|
|
| 113 |
<div class="chat-message bot">
|
| 114 |
Hi! Ask me anything about {{ result.name }}.<br>
|
| 115 |
<span style="color:#7C3AED; font-size:13px;">
|
|
|
|
| 116 |
Example: "How do I get started with this path?"
|
| 117 |
</span>
|
| 118 |
</div>
|
|
|
|
| 138 |
<button class="btn reset-btn" onclick="resetAssessment()">π Retake Assessment</button>
|
| 139 |
</div>
|
| 140 |
{% endif %}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 141 |
{% endif %}
|
| 142 |
</div>
|
| 143 |
<script src="{{ url_for('static', filename='script.js') }}"></script>
|
templates/landing.html
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="en">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>Spiritual Path Assessment</title>
|
| 7 |
+
<link rel="stylesheet" href="{{ url_for('static', filename='landing.css') }}">
|
| 8 |
+
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap" rel="stylesheet">
|
| 9 |
+
</head>
|
| 10 |
+
<body>
|
| 11 |
+
<div class="gradient-bg"></div>
|
| 12 |
+
|
| 13 |
+
<nav class="navbar">
|
| 14 |
+
<div class="nav-container">
|
| 15 |
+
<div class="logo">β¨ Spiritual Path</div>
|
| 16 |
+
<a href="/assessment" class="nav-cta">Start Assessment</a>
|
| 17 |
+
</div>
|
| 18 |
+
</nav>
|
| 19 |
+
|
| 20 |
+
<main class="main-content">
|
| 21 |
+
<section class="hero-section">
|
| 22 |
+
<div class="hero-container">
|
| 23 |
+
<div class="badge">π Discover Your Path</div>
|
| 24 |
+
<h1 class="hero-title">
|
| 25 |
+
Find Your <span class="gradient-text">Spiritual Journey</span>
|
| 26 |
+
</h1>
|
| 27 |
+
<p class="hero-subtitle">
|
| 28 |
+
A personalized assessment designed to help you explore and understand your unique spiritual path through thoughtful questions and AI-powered insights.
|
| 29 |
+
</p>
|
| 30 |
+
|
| 31 |
+
<div class="cta-buttons">
|
| 32 |
+
<a href="/assessment" class="btn-primary">
|
| 33 |
+
Begin Your Assessment
|
| 34 |
+
<span class="arrow">β</span>
|
| 35 |
+
</a>
|
| 36 |
+
<div class="assessment-meta">
|
| 37 |
+
<span>β±οΈ 5-10 minutes</span>
|
| 38 |
+
<span>π Completely free</span>
|
| 39 |
+
<span>π§ Personalized insights</span>
|
| 40 |
+
</div>
|
| 41 |
+
</div>
|
| 42 |
+
|
| 43 |
+
<div class="hero-visual" style="display: none;">
|
| 44 |
+
<div class="floating-card card-1">
|
| 45 |
+
<div class="card-icon">π§</div>
|
| 46 |
+
<div class="card-text">Personalized Insights</div>
|
| 47 |
+
</div>
|
| 48 |
+
<div class="floating-card card-2">
|
| 49 |
+
<div class="card-icon">π</div>
|
| 50 |
+
<div class="card-text">Deep Analysis</div>
|
| 51 |
+
</div>
|
| 52 |
+
<div class="floating-card card-3">
|
| 53 |
+
<div class="card-icon">π―</div>
|
| 54 |
+
<div class="card-text">Actionable Guidance</div>
|
| 55 |
+
</div>
|
| 56 |
+
</div>
|
| 57 |
+
</div>
|
| 58 |
+
</section>
|
| 59 |
+
|
| 60 |
+
<section class="features-section">
|
| 61 |
+
<div class="section-container">
|
| 62 |
+
<div class="section-header">
|
| 63 |
+
<h2>What You'll Discover</h2>
|
| 64 |
+
<p>Comprehensive insights into your spiritual journey</p>
|
| 65 |
+
</div>
|
| 66 |
+
|
| 67 |
+
<div class="features-grid">
|
| 68 |
+
<div class="feature-card">
|
| 69 |
+
<div class="feature-icon-wrapper">
|
| 70 |
+
<div class="feature-icon">π</div>
|
| 71 |
+
</div>
|
| 72 |
+
<h3>Your Spiritual Dimensions</h3>
|
| 73 |
+
<p>Understand your current spiritual development across multiple dimensions and uncover hidden aspects of your journey.</p>
|
| 74 |
+
</div>
|
| 75 |
+
|
| 76 |
+
<div class="feature-card">
|
| 77 |
+
<div class="feature-icon-wrapper">
|
| 78 |
+
<div class="feature-icon">π‘</div>
|
| 79 |
+
</div>
|
| 80 |
+
<h3>Personalized Recommendations</h3>
|
| 81 |
+
<p>Get specific guidance tailored to your unique spiritual path, beliefs, and goals for meaningful growth.</p>
|
| 82 |
+
</div>
|
| 83 |
+
|
| 84 |
+
<div class="feature-card">
|
| 85 |
+
<div class="feature-icon-wrapper">
|
| 86 |
+
<div class="feature-icon">π</div>
|
| 87 |
+
</div>
|
| 88 |
+
<h3>Growth Opportunities</h3>
|
| 89 |
+
<p>Identify areas for spiritual growth and receive practical steps to deepen your practice and understanding.</p>
|
| 90 |
+
</div>
|
| 91 |
+
</div>
|
| 92 |
+
</div>
|
| 93 |
+
</section>
|
| 94 |
+
|
| 95 |
+
<section class="cta-section">
|
| 96 |
+
<div class="cta-container">
|
| 97 |
+
<h2>Ready to begin your journey?</h2>
|
| 98 |
+
<p>Start your spiritual path assessment today</p>
|
| 99 |
+
<a href="/assessment" class="btn-secondary">
|
| 100 |
+
Get Started Now
|
| 101 |
+
<span class="arrow">β</span>
|
| 102 |
+
</a>
|
| 103 |
+
</div>
|
| 104 |
+
</section>
|
| 105 |
+
</main>
|
| 106 |
+
|
| 107 |
+
<footer class="footer">
|
| 108 |
+
<div class="footer-container">
|
| 109 |
+
<p>Β© 2025 Spiritual Path Assessment. Empowering your spiritual journey.</p>
|
| 110 |
+
</div>
|
| 111 |
+
</footer>
|
| 112 |
+
</body>
|
| 113 |
+
</html>
|