Update index.html
Browse files- index.html +555 -339
index.html
CHANGED
|
@@ -2,8 +2,8 @@
|
|
| 2 |
<html lang="th">
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
-
<meta name="viewport" content="width=device-width, initial-scale=1.0
|
| 6 |
-
<title
|
| 7 |
|
| 8 |
<!-- Tailwind CSS -->
|
| 9 |
<script src="https://cdn.tailwindcss.com"></script>
|
|
@@ -23,437 +23,653 @@
|
|
| 23 |
<!-- Font: Noto Sans Thai -->
|
| 24 |
<link href="https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@300;400;600;800&display=swap" rel="stylesheet">
|
| 25 |
|
| 26 |
-
<!--
|
| 27 |
-
|
|
|
|
|
|
|
|
|
|
| 28 |
|
| 29 |
<style>
|
| 30 |
body {
|
| 31 |
font-family: 'Noto Sans Thai', sans-serif;
|
| 32 |
-
background-color: #
|
| 33 |
color: #1F2937;
|
| 34 |
-
padding-bottom: 80px; /* Space for bottom nav */
|
| 35 |
-
overscroll-behavior-y: none; /* Prevent pull-to-refresh on mobile if desired */
|
| 36 |
}
|
| 37 |
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
width:
|
| 41 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
}
|
| 43 |
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
.tab-content.active {
|
| 50 |
-
display: block;
|
| 51 |
-
}
|
| 52 |
-
|
| 53 |
-
@keyframes fadeIn {
|
| 54 |
-
from { opacity: 0; transform: translateY(10px); }
|
| 55 |
-
to { opacity: 1; transform: translateY(0); }
|
| 56 |
}
|
| 57 |
|
| 58 |
-
.
|
| 59 |
-
color:
|
| 60 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 61 |
}
|
| 62 |
|
| 63 |
-
.
|
| 64 |
-
transform:
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
.card {
|
| 69 |
-
background: white;
|
| 70 |
-
border-radius: 1rem;
|
| 71 |
-
box-shadow: 0 2px 5px rgba(0,0,0,0.05);
|
| 72 |
-
padding: 1rem;
|
| 73 |
-
margin-bottom: 1rem;
|
| 74 |
}
|
| 75 |
|
| 76 |
-
.
|
| 77 |
-
|
| 78 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 79 |
}
|
| 80 |
|
| 81 |
-
/* Custom Loader */
|
| 82 |
.loader {
|
| 83 |
-
border:
|
| 84 |
-
border-top:
|
| 85 |
border-radius: 50%;
|
| 86 |
-
width:
|
| 87 |
-
height:
|
| 88 |
animation: spin 1s linear infinite;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 89 |
}
|
| 90 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 91 |
</style>
|
| 92 |
</head>
|
| 93 |
-
<body>
|
| 94 |
-
|
| 95 |
-
<!--
|
| 96 |
-
<header class="
|
| 97 |
-
<div class="
|
| 98 |
-
<div class="
|
| 99 |
-
|
| 100 |
-
ธ.
|
| 101 |
-
</div>
|
| 102 |
-
<div>
|
| 103 |
-
<h1 class="text-lg font-bold leading-tight">ธนอนันต์ เมนะสวัสดิ์</h1>
|
| 104 |
-
<p class="text-xs text-purple-200">อุดรธานี เขต 6 | พรรคกล้าธรรม</p>
|
| 105 |
-
</div>
|
| 106 |
-
</div>
|
| 107 |
-
<div class="bg-yellow-400 text-purple-900 text-xs font-bold px-2 py-1 rounded">
|
| 108 |
-
D-90
|
| 109 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 110 |
</div>
|
| 111 |
</header>
|
| 112 |
|
| 113 |
-
|
| 114 |
-
<div class="h-20"></div>
|
| 115 |
|
| 116 |
-
|
| 117 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 118 |
|
| 119 |
-
<!--
|
| 120 |
-
<
|
| 121 |
-
|
| 122 |
-
|
| 123 |
-
|
| 124 |
-
|
| 125 |
-
|
| 126 |
-
|
| 127 |
-
<div class="card bg-yellow-50 border-l-4 border-yellow-500 !mb-0">
|
| 128 |
-
<p class="text-xs text-gray-500 uppercase">New Gen</p>
|
| 129 |
-
<p class="text-2xl font-bold text-yellow-600">35%</p>
|
| 130 |
</div>
|
|
|
|
| 131 |
</div>
|
| 132 |
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
<
|
| 136 |
-
<
|
| 137 |
-
|
| 138 |
-
|
| 139 |
-
|
| 140 |
-
<div
|
| 141 |
-
|
| 142 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 143 |
</div>
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
<
|
| 147 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 148 |
</div>
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
<
|
| 152 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 153 |
</div>
|
| 154 |
</div>
|
| 155 |
</div>
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
|
| 159 |
-
|
| 160 |
-
|
| 161 |
-
|
| 162 |
-
|
| 163 |
-
|
| 164 |
-
|
| 165 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 166 |
</div>
|
|
|
|
|
|
|
|
|
|
| 167 |
</div>
|
| 168 |
-
<div class="
|
| 169 |
-
|
| 170 |
-
|
| 171 |
-
|
| 172 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 173 |
</div>
|
|
|
|
|
|
|
|
|
|
| 174 |
</div>
|
|
|
|
| 175 |
</div>
|
| 176 |
</div>
|
| 177 |
-
</
|
| 178 |
|
| 179 |
-
<!--
|
| 180 |
-
<
|
| 181 |
-
<
|
| 182 |
-
|
| 183 |
-
|
| 184 |
-
|
| 185 |
-
|
| 186 |
-
|
| 187 |
-
|
|
|
|
| 188 |
</div>
|
|
|
|
| 189 |
</div>
|
| 190 |
|
| 191 |
-
|
| 192 |
-
|
| 193 |
-
|
| 194 |
-
|
| 195 |
-
<
|
| 196 |
-
|
| 197 |
-
|
| 198 |
-
|
| 199 |
-
|
| 200 |
-
|
| 201 |
-
|
| 202 |
-
|
| 203 |
-
|
| 204 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 205 |
</div>
|
| 206 |
</div>
|
| 207 |
-
|
| 208 |
-
|
| 209 |
-
|
| 210 |
-
|
| 211 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 212 |
</div>
|
|
|
|
| 213 |
</div>
|
| 214 |
-
</div>
|
| 215 |
|
| 216 |
-
<!-- Competitor Radar -->
|
| 217 |
-
<div class="card mt-4">
|
| 218 |
-
<h4 class="text-sm font-bold text-gray-600 mb-2 text-center">เทียบฟอร์มคู่แข่ง (SWOT)</h4>
|
| 219 |
-
<div style="height: 250px;">
|
| 220 |
-
<canvas id="mobileRadarChart"></canvas>
|
| 221 |
-
</div>
|
| 222 |
</div>
|
| 223 |
-
</
|
| 224 |
-
|
| 225 |
-
<!--
|
| 226 |
-
<
|
| 227 |
-
<div class="
|
| 228 |
-
<
|
| 229 |
-
<
|
|
|
|
|
|
|
| 230 |
</div>
|
| 231 |
-
|
| 232 |
-
|
| 233 |
-
|
| 234 |
-
|
| 235 |
-
|
| 236 |
-
<div class="w-8 h-8 rounded bg-gradient-to-br from-pink-500 to-orange-400 text-white flex items-center justify-center"><i class="fas fa-pen-nib"></i></div>
|
| 237 |
-
<h3 class="font-bold text-gray-700">เขียนแคปชั่น</h3>
|
| 238 |
</div>
|
| 239 |
-
<i class="fas fa-chevron-down text-gray-400 transition-transform group-open:rotate-180"></i>
|
| 240 |
</div>
|
| 241 |
-
<div
|
| 242 |
-
<
|
| 243 |
-
<
|
| 244 |
-
<
|
| 245 |
-
|
| 246 |
-
|
| 247 |
-
|
| 248 |
-
|
| 249 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 250 |
</div>
|
| 251 |
</div>
|
| 252 |
-
|
| 253 |
-
|
| 254 |
-
|
| 255 |
-
|
| 256 |
-
|
| 257 |
-
|
| 258 |
-
|
| 259 |
-
|
| 260 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 261 |
</div>
|
| 262 |
-
|
| 263 |
-
|
| 264 |
-
<
|
| 265 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 266 |
</div>
|
| 267 |
-
|
| 268 |
-
|
| 269 |
-
|
| 270 |
-
|
| 271 |
-
|
| 272 |
-
<
|
| 273 |
-
<
|
| 274 |
-
<
|
| 275 |
-
|
| 276 |
-
|
| 277 |
-
</div>
|
| 278 |
-
<div id="tool-policy" class="hidden mt-4 pt-4 border-t">
|
| 279 |
-
<textarea id="mPolicyInput" rows="2" class="w-full text-sm border-gray-300 border rounded-lg p-2 bg-gray-50 mb-2" placeholder="นโยบายภาษาราชการ..."></textarea>
|
| 280 |
-
<select id="mPolicyTarget" class="w-full text-sm border-gray-300 border rounded-lg p-2 bg-gray-50 mb-3">
|
| 281 |
-
<option value="ผู้เฒ่าผู้แก่">คนเฒ่าคนแก่ (อีสาน)</option>
|
| 282 |
-
<option value="วัยรุ่น">วัยรุ่น (สั้นๆ)</option>
|
| 283 |
-
</select>
|
| 284 |
-
<button id="btnMPolicy" class="w-full bg-yellow-500 text-white rounded-lg py-2 text-sm font-bold shadow hover:bg-yellow-600 transition">🗣️ แปลงภาษา</button>
|
| 285 |
-
<div id="outMPolicy" class="mt-3 p-3 bg-yellow-50 rounded-lg text-xs text-gray-800 hidden border border-yellow-200"></div>
|
| 286 |
</div>
|
| 287 |
</div>
|
|
|
|
| 288 |
|
| 289 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 290 |
|
| 291 |
</main>
|
| 292 |
|
| 293 |
-
<!--
|
| 294 |
-
<nav class="fixed bottom-0 left-0 right-0 bg-white border-t border-gray-200 pb-safe pt-2 px-6 flex justify-between items-center z-50 h-[70px]">
|
| 295 |
-
<button onclick="switchTab('tab-home')" class="nav-item active flex flex-col items-center gap-1 text-gray-400 w-16">
|
| 296 |
-
<i class="fas fa-home text-xl"></i>
|
| 297 |
-
<span class="text-[10px]">หน้าหลัก</span>
|
| 298 |
-
</button>
|
| 299 |
-
<button onclick="switchTab('tab-warroom')" class="nav-item flex flex-col items-center gap-1 text-gray-400 w-16">
|
| 300 |
-
<i class="fas fa-chess-knight text-xl"></i>
|
| 301 |
-
<span class="text-[10px]">กลยุทธ์</span>
|
| 302 |
-
</button>
|
| 303 |
-
<button onclick="switchTab('tab-ai')" class="nav-item flex flex-col items-center gap-1 text-gray-400 w-16">
|
| 304 |
-
<div class="bg-gradient-to-tr from-purple-600 to-indigo-600 w-10 h-10 rounded-full flex items-center justify-center text-white shadow-lg -mt-6 border-4 border-gray-100">
|
| 305 |
-
<i class="fas fa-robot text-lg"></i>
|
| 306 |
-
</div>
|
| 307 |
-
<span class="text-[10px] mt-1 text-purple-700 font-bold">AI Helper</span>
|
| 308 |
-
</button>
|
| 309 |
-
<button onclick="alert('Coming Soon: ข้อมูลคู่แข่งและพื้นที่')" class="nav-item flex flex-col items-center gap-1 text-gray-400 w-16">
|
| 310 |
-
<i class="fas fa-map-marked-alt text-xl"></i>
|
| 311 |
-
<span class="text-[10px]">พื้นที่</span>
|
| 312 |
-
</button>
|
| 313 |
-
</nav>
|
| 314 |
-
|
| 315 |
-
<!-- JAVASCRIPT -->
|
| 316 |
<script type="module">
|
| 317 |
import { GoogleGenerativeAI } from "@google/generative-ai";
|
| 318 |
|
| 319 |
-
// --- API
|
| 320 |
-
const apiKey = "AIzaSyBlvdz3wUNm2PtiuYnN2al9L7krngami-E";
|
| 321 |
const genAI = new GoogleGenerativeAI(apiKey);
|
| 322 |
const model = genAI.getGenerativeModel({ model: "gemini-2.5-flash-preview-09-2025" });
|
| 323 |
|
| 324 |
-
|
| 325 |
-
|
| 326 |
-
|
| 327 |
-
|
| 328 |
-
|
| 329 |
-
|
| 330 |
-
|
| 331 |
-
|
| 332 |
-
|
| 333 |
-
|
| 334 |
-
|
| 335 |
-
|
| 336 |
-
|
| 337 |
-
|
| 338 |
-
|
| 339 |
-
|
| 340 |
-
|
| 341 |
}
|
| 342 |
}
|
| 343 |
|
| 344 |
-
|
| 345 |
-
|
| 346 |
-
|
| 347 |
-
|
| 348 |
-
|
| 349 |
-
async function runAI(btnId, outId, prompt, loadingText="กำลังคิด...") {
|
| 350 |
-
const btn = document.getElementById(btnId);
|
| 351 |
-
const out = document.getElementById(outId);
|
| 352 |
-
const originalText = btn.innerHTML;
|
| 353 |
|
| 354 |
-
|
| 355 |
-
|
| 356 |
-
out.classList.remove('hidden');
|
| 357 |
-
out.innerText = "Waiting for AI...";
|
| 358 |
|
| 359 |
try {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 360 |
const result = await model.generateContent(prompt);
|
| 361 |
-
|
|
|
|
| 362 |
} catch (error) {
|
| 363 |
-
|
| 364 |
} finally {
|
| 365 |
-
|
| 366 |
-
btn.innerHTML = originalText;
|
| 367 |
}
|
| 368 |
-
}
|
| 369 |
-
|
| 370 |
-
// --- AI FEATURES ---
|
| 371 |
|
| 372 |
-
//
|
| 373 |
-
document.getElementById('
|
| 374 |
-
const
|
| 375 |
-
const
|
| 376 |
-
if(!topic) return alert('ใส่หัวข้อก่อนครับ');
|
| 377 |
|
| 378 |
-
|
| 379 |
-
|
| 380 |
-
|
| 381 |
-
|
| 382 |
-
|
| 383 |
-
|
| 384 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 385 |
});
|
| 386 |
|
| 387 |
-
//
|
| 388 |
-
document.getElementById('
|
| 389 |
-
const
|
| 390 |
-
|
|
|
|
| 391 |
|
| 392 |
-
|
| 393 |
-
|
| 394 |
-
|
|
|
|
|
|
|
| 395 |
|
| 396 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 397 |
});
|
| 398 |
|
| 399 |
-
// 3
|
| 400 |
-
document.getElementById('
|
| 401 |
-
const
|
| 402 |
-
const
|
| 403 |
-
|
| 404 |
|
| 405 |
-
|
| 406 |
-
|
| 407 |
-
|
| 408 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 409 |
});
|
| 410 |
|
| 411 |
-
//
|
| 412 |
-
|
| 413 |
-
|
| 414 |
-
|
| 415 |
-
|
| 416 |
-
|
| 417 |
-
|
| 418 |
-
|
| 419 |
-
|
| 420 |
-
|
| 421 |
-
|
| 422 |
-
|
| 423 |
-
}
|
| 424 |
-
|
| 425 |
-
|
| 426 |
-
|
| 427 |
-
|
| 428 |
-
|
| 429 |
-
|
| 430 |
-
|
| 431 |
-
|
| 432 |
-
|
| 433 |
-
|
| 434 |
-
|
| 435 |
-
|
| 436 |
-
|
| 437 |
-
|
| 438 |
-
|
| 439 |
-
|
| 440 |
-
|
| 441 |
-
|
| 442 |
-
|
| 443 |
-
|
| 444 |
-
borderDash: [5, 5],
|
| 445 |
-
pointRadius: 0
|
| 446 |
-
}]
|
| 447 |
-
},
|
| 448 |
-
options: {
|
| 449 |
-
responsive: true,
|
| 450 |
-
maintainAspectRatio: false,
|
| 451 |
-
scales: { r: { suggestedMin: 0, ticks: { display: false } } },
|
| 452 |
-
plugins: { legend: { position: 'bottom' } }
|
| 453 |
-
}
|
| 454 |
-
});
|
| 455 |
-
}, 500);
|
| 456 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 457 |
</script>
|
| 458 |
</body>
|
| 459 |
</html>
|
|
|
|
| 2 |
<html lang="th">
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>ยุทธศาสตร์เลือกตั้ง 2569: ธนอนันต์ เมนะสวัสดิ์ (อุดรฯ เขต 6)</title>
|
| 7 |
|
| 8 |
<!-- Tailwind CSS -->
|
| 9 |
<script src="https://cdn.tailwindcss.com"></script>
|
|
|
|
| 23 |
<!-- Font: Noto Sans Thai -->
|
| 24 |
<link href="https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@300;400;600;800&display=swap" rel="stylesheet">
|
| 25 |
|
| 26 |
+
<!-- Palette: Kla Tham Party Theme (Purple/Gold/Bold)
|
| 27 |
+
Primary: #6A0DAD (Purple)
|
| 28 |
+
Secondary: #FFD700 (Gold)
|
| 29 |
+
Accent: #FF4500 (Orange Red - Action)
|
| 30 |
+
-->
|
| 31 |
|
| 32 |
<style>
|
| 33 |
body {
|
| 34 |
font-family: 'Noto Sans Thai', sans-serif;
|
| 35 |
+
background-color: #F8F7FF; /* Light Purple Tint */
|
| 36 |
color: #1F2937;
|
|
|
|
|
|
|
| 37 |
}
|
| 38 |
|
| 39 |
+
.chart-container {
|
| 40 |
+
position: relative;
|
| 41 |
+
width: 100%;
|
| 42 |
+
max-width: 600px;
|
| 43 |
+
margin-left: auto;
|
| 44 |
+
margin-right: auto;
|
| 45 |
+
height: 350px;
|
| 46 |
+
max-height: 400px;
|
| 47 |
}
|
| 48 |
|
| 49 |
+
@media (min-width: 768px) {
|
| 50 |
+
.chart-container {
|
| 51 |
+
height: 400px;
|
| 52 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 53 |
}
|
| 54 |
|
| 55 |
+
.info-card {
|
| 56 |
+
background-color: white;
|
| 57 |
+
border-radius: 0.75rem;
|
| 58 |
+
box-shadow: 0 4px 6px -1px rgba(106, 13, 173, 0.1), 0 2px 4px -1px rgba(106, 13, 173, 0.06);
|
| 59 |
+
padding: 1.5rem;
|
| 60 |
+
transition: transform 0.2s;
|
| 61 |
+
border-top: 4px solid transparent;
|
| 62 |
}
|
| 63 |
|
| 64 |
+
.info-card:hover {
|
| 65 |
+
transform: translateY(-2px);
|
| 66 |
+
border-top-color: #6A0DAD;
|
| 67 |
+
box-shadow: 0 10px 15px -3px rgba(106, 13, 173, 0.15), 0 4px 6px -2px rgba(106, 13, 173, 0.1);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 68 |
}
|
| 69 |
|
| 70 |
+
.timeline-dot {
|
| 71 |
+
width: 16px;
|
| 72 |
+
height: 16px;
|
| 73 |
+
background-color: #6A0DAD;
|
| 74 |
+
border-radius: 50%;
|
| 75 |
+
border: 3px solid #fff;
|
| 76 |
+
box-shadow: 0 0 0 2px #6A0DAD;
|
| 77 |
}
|
| 78 |
|
|
|
|
| 79 |
.loader {
|
| 80 |
+
border: 4px solid #f3f3f3;
|
| 81 |
+
border-top: 4px solid #6A0DAD;
|
| 82 |
border-radius: 50%;
|
| 83 |
+
width: 24px;
|
| 84 |
+
height: 24px;
|
| 85 |
animation: spin 1s linear infinite;
|
| 86 |
+
display: inline-block;
|
| 87 |
+
}
|
| 88 |
+
|
| 89 |
+
@keyframes spin {
|
| 90 |
+
0% { transform: rotate(0deg); }
|
| 91 |
+
100% { transform: rotate(360deg); }
|
| 92 |
}
|
| 93 |
+
|
| 94 |
+
/* Platform Icons */
|
| 95 |
+
.icon-tiktok { color: #000000; }
|
| 96 |
+
.icon-line { color: #00B900; }
|
| 97 |
+
.icon-fb { color: #1877F2; }
|
| 98 |
</style>
|
| 99 |
</head>
|
| 100 |
+
<body class="bg-gray-100">
|
| 101 |
+
|
| 102 |
+
<!-- Header Section -->
|
| 103 |
+
<header class="bg-gradient-to-r from-purple-800 via-purple-700 to-indigo-900 text-white py-12 px-4 shadow-xl">
|
| 104 |
+
<div class="max-w-6xl mx-auto text-center">
|
| 105 |
+
<div class="inline-block bg-white text-purple-900 px-4 py-1 rounded-full text-sm font-bold mb-4 tracking-wide shadow-md">
|
| 106 |
+
ROADMAP TO VICTORY 2026 (2569)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 107 |
</div>
|
| 108 |
+
<h1 class="text-4xl md:text-6xl font-extrabold mb-2 tracking-tight">ธนอนันต์ เมนะสวัสดิ์</h1>
|
| 109 |
+
<h2 class="text-2xl md:text-3xl font-light opacity-90">พรรคกล้าธรรม | อุดรธานี เขต 6</h2>
|
| 110 |
+
<p class="mt-6 text-lg max-w-3xl mx-auto text-purple-100">
|
| 111 |
+
"สานต่อตำนาน เมนะสวัสดิ์ - กล้าทำจริง เพื่อพี่น้องอุดรฯ" <br>
|
| 112 |
+
ยุทธศาสตร์ผสมผสานฐานเสียงดั้งเดิม + พลังโซเชียลมีเดียยุคใหม่
|
| 113 |
+
</p>
|
| 114 |
</div>
|
| 115 |
</header>
|
| 116 |
|
| 117 |
+
<main class="max-w-7xl mx-auto p-4 md:p-8 space-y-12">
|
|
|
|
| 118 |
|
| 119 |
+
<!-- Intro Stats Row -->
|
| 120 |
+
<section class="grid grid-cols-1 md:grid-cols-4 gap-6">
|
| 121 |
+
<div class="info-card border-l-8 border-purple-600 text-center">
|
| 122 |
+
<div class="text-gray-500 font-bold uppercase text-xs tracking-wider">เป้าหมายคะแนน</div>
|
| 123 |
+
<div class="text-4xl font-extrabold text-purple-700 mt-2">42,000+</div>
|
| 124 |
+
<div class="text-gray-600 text-sm mt-1">คะแนนเสียง</div>
|
| 125 |
+
</div>
|
| 126 |
+
<div class="info-card border-l-8 border-yellow-500 text-center">
|
| 127 |
+
<div class="text-gray-500 font-bold uppercase text-xs tracking-wider">กลุ่มเป้าหมายหลัก</div>
|
| 128 |
+
<div class="text-4xl font-extrabold text-yellow-600 mt-2">New Gen</div>
|
| 129 |
+
<div class="text-gray-600 text-sm mt-1">อายุ 18-35 ปี (35%)</div>
|
| 130 |
+
</div>
|
| 131 |
+
<div class="info-card border-l-8 border-indigo-500 text-center">
|
| 132 |
+
<div class="text-gray-500 font-bold uppercase text-xs tracking-wider">ฐานเสียงเดิม</div>
|
| 133 |
+
<div class="text-4xl font-extrabold text-indigo-600 mt-2">Family</div>
|
| 134 |
+
<div class="text-gray-600 text-sm mt-1">ตระกูลเมนะสวัสดิ์</div>
|
| 135 |
+
</div>
|
| 136 |
+
<div class="info-card border-l-8 border-pink-500 text-center">
|
| 137 |
+
<div class="text-gray-500 font-bold uppercase text-xs tracking-wider">งบดิจิทัล</div>
|
| 138 |
+
<div class="text-4xl font-extrabold text-pink-600 mt-2">40%</div>
|
| 139 |
+
<div class="text-gray-600 text-sm mt-1">ของงบทั้งหมด</div>
|
| 140 |
+
</div>
|
| 141 |
+
</section>
|
| 142 |
|
| 143 |
+
<!-- Digital War Room Strategy -->
|
| 144 |
+
<section id="digital-war-room" class="bg-white rounded-2xl shadow-xl overflow-hidden border border-purple-100">
|
| 145 |
+
<div class="bg-gray-900 text-white p-6 border-b-4 border-purple-500 flex justify-between items-center flex-wrap gap-4">
|
| 146 |
+
<div>
|
| 147 |
+
<h3 class="text-2xl font-bold flex items-center gap-2">
|
| 148 |
+
📱 Digital War Room 2026
|
| 149 |
+
</h3>
|
| 150 |
+
<p class="text-gray-400 text-sm mt-1">ยุทธศาสตร์เจาะลึกโซเชียลมีเดียรายแพลตฟอร์ม สำหรับ "ธนอนันต์"</p>
|
|
|
|
|
|
|
|
|
|
| 151 |
</div>
|
| 152 |
+
<span class="bg-purple-600 px-3 py-1 rounded text-xs font-bold animate-pulse">LIVE MONITORING</span>
|
| 153 |
</div>
|
| 154 |
|
| 155 |
+
<div class="p-6 md:p-8 grid grid-cols-1 lg:grid-cols-2 gap-8">
|
| 156 |
+
<!-- Left: Platform Strategy -->
|
| 157 |
+
<div class="space-y-6">
|
| 158 |
+
<h4 class="font-bold text-gray-800 text-lg border-b pb-2">🎯 กลยุทธ์แยกแพลตฟอร์ม (Platform Specifics)</h4>
|
| 159 |
+
<!-- TikTok -->
|
| 160 |
+
<div class="flex gap-4 items-start p-4 bg-gray-50 rounded-xl hover:bg-gray-100 transition">
|
| 161 |
+
<div class="bg-black text-white p-3 rounded-lg text-2xl">🎵</div>
|
| 162 |
+
<div>
|
| 163 |
+
<h5 class="font-bold text-gray-900">TikTok: "The Real Udon"</h5>
|
| 164 |
+
<p class="text-sm text-gray-600 mt-1">
|
| 165 |
+
<strong>Target:</strong> First Voters & วัยทำงาน<br>
|
| 166 |
+
<strong>Concept:</strong> "เข้าถึงง่าย ไม่ถือตัว"<br>
|
| 167 |
+
<strong>Action:</strong> คลิปสั้น 30 วิฯ โชว์แก้ปัญหาหน้างานจริง (เช่น ท่อแตก ถนนพัง ไปดูทันที) ใช้ภาษาอีสาน 100% ดันแฮชแท็ก #ธนอนันต์จัดให้ #กล้าธรรมอุดร
|
| 168 |
+
</p>
|
| 169 |
+
</div>
|
| 170 |
</div>
|
| 171 |
+
<!-- Line OA -->
|
| 172 |
+
<div class="flex gap-4 items-start p-4 bg-gray-50 rounded-xl hover:bg-gray-100 transition">
|
| 173 |
+
<div class="bg-green-500 text-white p-3 rounded-lg text-2xl">💬</div>
|
| 174 |
+
<div>
|
| 175 |
+
<h5 class="font-bold text-gray-900">Line OA: "Menasawat Connect"</h5>
|
| 176 |
+
<p class="text-sm text-gray-600 mt-1">
|
| 177 |
+
<strong>Target:</strong> หัวคะแนนธรรมชาติ & ผู้นำชุมชน<br>
|
| 178 |
+
<strong>Concept:</strong> "สายตรง แก้ไว"<br>
|
| 179 |
+
<strong>Action:</strong> ระบบ CRM แจ้งข่าวนโยบายพรรคกล้าธรรม แบ่งกลุ่มบรอดแคสต์ (ชาวนา/ค้าขาย/ข้าราชการ) ส่งสวัสดีตอนเช้าพร้อมรูปภารกิจจริง
|
| 180 |
+
</p>
|
| 181 |
+
</div>
|
| 182 |
</div>
|
| 183 |
+
<!-- Facebook -->
|
| 184 |
+
<div class="flex gap-4 items-start p-4 bg-gray-50 rounded-xl hover:bg-gray-100 transition">
|
| 185 |
+
<div class="bg-blue-600 text-white p-3 rounded-lg text-2xl">f</div>
|
| 186 |
+
<div>
|
| 187 |
+
<h5 class="font-bold text-gray-900">Facebook Page: "Official Voice"</h5>
|
| 188 |
+
<p class="text-sm text-gray-600 mt-1">
|
| 189 |
+
<strong>Target:</strong> ฐานเสียงเดิม & ผู้ใหญ่บ้าน<br>
|
| 190 |
+
<strong>Concept:</strong> "งานหนัก งานจริง"<br>
|
| 191 |
+
<strong>Action:</strong> Live Stream งานบุญประเพณี โชว์วิสัยทัศน์ยาวๆ และอัลบั้มรูป "ก่อนทำ-หลังทำ" เน้นผลงานพรรคกล้าธรรม
|
| 192 |
+
</p>
|
| 193 |
+
</div>
|
| 194 |
+
</div>
|
| 195 |
+
</div>
|
| 196 |
+
<!-- Right: Chart & Timeline -->
|
| 197 |
+
<div class="space-y-6">
|
| 198 |
+
<h4 class="font-bold text-gray-800 text-lg border-b pb-2">📊 ส่วนแบ่งการสื่อสาร (Voice Share Targets)</h4>
|
| 199 |
+
<div class="chart-container" style="height: 250px;">
|
| 200 |
+
<canvas id="socialChart"></canvas>
|
| 201 |
+
</div>
|
| 202 |
+
<div class="bg-purple-50 p-4 rounded-xl border border-purple-200 mt-4">
|
| 203 |
+
<h5 class="font-bold text-purple-800 text-sm mb-2">💡 Insight ปี 2569:</h5>
|
| 204 |
+
<p class="text-xs text-purple-700">
|
| 205 |
+
"การเลือกตั้งปี 69 AI จะมีบทบาทสูงในการสร้างเฟคนิวส์ (Deepfake) ทีมงานต้องมีหน่วย 'Fact Check' ที่ตอบโต้ได้ภายใน 1 ชม. ผ่าน Line OA และ TikTok Reply"
|
| 206 |
+
</p>
|
| 207 |
</div>
|
| 208 |
</div>
|
| 209 |
</div>
|
| 210 |
+
</section>
|
| 211 |
+
|
| 212 |
+
<!-- AI Strategic Partner Section 1 -->
|
| 213 |
+
<section class="bg-gradient-to-br from-indigo-900 to-purple-800 rounded-2xl p-8 text-white shadow-xl relative overflow-hidden">
|
| 214 |
+
<div class="absolute top-0 right-0 -mr-16 -mt-16 w-64 h-64 rounded-full bg-white opacity-5"></div>
|
| 215 |
+
<div class="mb-8 border-b border-purple-400 pb-4 relative z-10">
|
| 216 |
+
<h3 class="text-3xl font-bold text-white flex items-center gap-3">
|
| 217 |
+
🤖 AI Strategic Partner <span class="text-sm bg-yellow-500 text-black px-2 py-1 rounded font-bold">GEMINI INTEGRATED</span>
|
| 218 |
+
</h3>
|
| 219 |
+
<p class="text-purple-200 mt-2">
|
| 220 |
+
ผู้ช่วยวางแผนสำหรับ "ธนอนันต์" โดยเฉพาะ: เขียนแคปชั่นและแก้เกมการเมือง
|
| 221 |
+
</p>
|
| 222 |
+
</div>
|
| 223 |
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-8 relative z-10">
|
| 224 |
+
<!-- Feature 1: Social Media Caption Creator -->
|
| 225 |
+
<div class="bg-white text-gray-800 rounded-xl p-6 shadow-lg">
|
| 226 |
+
<h4 class="text-xl font-bold text-purple-800 mb-4 flex items-center">
|
| 227 |
+
✍️ ผู้ช่วยเขียนแคปชั่น (Caption Generator)
|
| 228 |
+
</h4>
|
| 229 |
+
<div class="space-y-4">
|
| 230 |
+
<div>
|
| 231 |
+
<label class="block text-sm font-semibold text-gray-700 mb-1">หัวข้อคอนเทนต์ (Topic)</label>
|
| 232 |
+
<input type="text" id="captionTopic" class="w-full border-gray-300 border rounded-md p-2 bg-gray-50" placeholder="เช่น ลงพื้นที่น้ำท่วม, งานบุญบั้งไฟ...">
|
| 233 |
+
</div>
|
| 234 |
+
<div>
|
| 235 |
+
<label class="block text-sm font-semibold text-gray-700 mb-1">แพลตฟอร์ม (Platform)</label>
|
| 236 |
+
<select id="captionPlatform" class="w-full border-gray-300 border rounded-md p-2 bg-gray-50">
|
| 237 |
+
<option value="TikTok">TikTok (สั้น สนุก กันเอง)</option>
|
| 238 |
+
<option value="Facebook">Facebook (ทางการ น่าเชื่อถือ)</option>
|
| 239 |
+
<option value="Line Official">Line OA (ใส่ใจ แจ้งข่าว)</option>
|
| 240 |
+
</select>
|
| 241 |
</div>
|
| 242 |
+
<button id="btnGenerateCaption" class="w-full bg-gradient-to-r from-purple-600 to-indigo-600 hover:from-purple-700 hover:to-indigo-700 text-white font-bold py-2 px-4 rounded-md transition flex justify-center items-center gap-2">
|
| 243 |
+
<span>✨ สร้างแคปชั่นสไตล์ "กล้าธรรม"</span>
|
| 244 |
+
</button>
|
| 245 |
</div>
|
| 246 |
+
<div id="captionOutput" class="mt-4 p-4 bg-purple-50 rounded-md border border-purple-200 min-h-[100px] text-sm text-gray-700 whitespace-pre-wrap hidden"></div>
|
| 247 |
+
</div>
|
| 248 |
+
<!-- Feature 2: Crisis Strategy -->
|
| 249 |
+
<div class="bg-white text-gray-800 rounded-xl p-6 shadow-lg">
|
| 250 |
+
<h4 class="text-xl font-bold text-purple-800 mb-4 flex items-center">
|
| 251 |
+
🛡️ ที่ปรึกษาแก้เกม (Crisis Advisor)
|
| 252 |
+
</h4>
|
| 253 |
+
<div class="space-y-4">
|
| 254 |
+
<div>
|
| 255 |
+
<label class="block text-sm font-semibold text-gray-700 mb-1">ประเด็นโจมตี/ดราม่า</label>
|
| 256 |
+
<textarea id="crisisInput" rows="3" class="w-full border-gray-300 border rounded-md p-2 bg-gray-50" placeholder="เช่น โดนกล่าวหาว่าซื้อเสียง, นโยบายพรรคทำไม่ได้จริง..."></textarea>
|
| 257 |
</div>
|
| 258 |
+
<button id="btnGenerateStrategy" class="w-full bg-gray-800 hover:bg-gray-900 text-white font-bold py-2 px-4 rounded-md transition flex justify-center items-center gap-2">
|
| 259 |
+
<span>✨ ขอคำแนะนำแก้เกม</span>
|
| 260 |
+
</button>
|
| 261 |
</div>
|
| 262 |
+
<div id="strategyOutput" class="mt-4 p-4 bg-gray-50 rounded-md border border-gray-200 min-h-[100px] text-sm text-gray-700 whitespace-pre-wrap hidden"></div>
|
| 263 |
</div>
|
| 264 |
</div>
|
| 265 |
+
</section>
|
| 266 |
|
| 267 |
+
<!-- New Section: AI Debate & Policy Lab -->
|
| 268 |
+
<section class="bg-gray-800 rounded-2xl p-8 text-white shadow-xl relative border-t-4 border-yellow-500">
|
| 269 |
+
<div class="mb-8 relative z-10 flex justify-between items-center">
|
| 270 |
+
<div>
|
| 271 |
+
<h3 class="text-3xl font-bold text-yellow-400 flex items-center gap-3">
|
| 272 |
+
🗳️ AI Debate & Policy Lab
|
| 273 |
+
</h3>
|
| 274 |
+
<p class="text-gray-300 mt-2">
|
| 275 |
+
ห้องปฏิบัติการนโยบายและฝึกซ้อมดีเบต: เตรียมพร้อมรับมือทุกคำถามและเข้าถึงทุกกลุ่มเป้าหมาย
|
| 276 |
+
</p>
|
| 277 |
</div>
|
| 278 |
+
<div class="hidden md:block text-5xl opacity-20">🎙️</div>
|
| 279 |
</div>
|
| 280 |
|
| 281 |
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-8">
|
| 282 |
+
|
| 283 |
+
<!-- Feature 3: Debate Simulator -->
|
| 284 |
+
<div class="bg-gray-700 rounded-xl p-6 border border-gray-600">
|
| 285 |
+
<h4 class="text-xl font-bold text-white mb-4 flex items-center">
|
| 286 |
+
🗣️ ห้องซ้อมดีเบต (Debate Simulator)
|
| 287 |
+
</h4>
|
| 288 |
+
<p class="text-xs text-gray-400 mb-4">AI จะสวมบทเป็นฝ่ายค้านเพื่อตั้งคำถามเจาะใจดำคุณ</p>
|
| 289 |
+
|
| 290 |
+
<div class="space-y-4">
|
| 291 |
+
<select id="debateTopic" class="w-full bg-gray-800 border border-gray-600 rounded p-2 text-white">
|
| 292 |
+
<option value="ราคาพืชผลการเกษตร">ราคาพืชผลการเกษตร</option>
|
| 293 |
+
<option value="ปัญหาที่ดิน ส.ป.ก.">ปัญหาที่ดิน ส.ป.ก.</option>
|
| 294 |
+
<option value="ยาเสพติดในชุมชน">ยาเสพติดในชุมชน</option>
|
| 295 |
+
<option value="การพัฒนาแหล่งน้ำ">การพัฒนาแหล่งน้ำ</option>
|
| 296 |
+
</select>
|
| 297 |
+
<button id="btnStartDebate" class="w-full bg-red-600 hover:bg-red-700 text-white font-bold py-2 px-4 rounded transition">
|
| 298 |
+
👊 เริ่มการท้าดวล (ให้ AI ตั้งคำถาม)
|
| 299 |
+
</button>
|
| 300 |
+
|
| 301 |
+
<div id="debateQuestionSection" class="hidden animate-in fade-in slide-in-from-top-4 duration-300">
|
| 302 |
+
<div class="p-3 bg-red-900/50 border-l-4 border-red-500 text-red-100 italic mb-2" id="debateQuestionText">
|
| 303 |
+
<!-- Question goes here -->
|
| 304 |
+
</div>
|
| 305 |
+
<textarea id="debateAnswer" rows="3" class="w-full bg-gray-800 border border-gray-600 rounded p-2 text-white" placeholder="พิมพ์คำตอบของคุณที่นี่..."></textarea>
|
| 306 |
+
<button id="btnGradeAnswer" class="mt-2 w-full bg-green-600 hover:bg-green-700 text-white font-bold py-2 px-4 rounded transition">
|
| 307 |
+
✅ ตรวจคำตอบ
|
| 308 |
+
</button>
|
| 309 |
+
</div>
|
| 310 |
+
|
| 311 |
+
<div id="debateFeedback" class="hidden p-4 bg-gray-900 rounded border border-gray-700 text-sm whitespace-pre-wrap text-gray-300"></div>
|
| 312 |
</div>
|
| 313 |
</div>
|
| 314 |
+
|
| 315 |
+
<!-- Feature 4: Policy Localizer -->
|
| 316 |
+
<div class="bg-gray-700 rounded-xl p-6 border border-gray-600">
|
| 317 |
+
<h4 class="text-xl font-bold text-white mb-4 flex items-center">
|
| 318 |
+
📢 เครื่องแปลนโยบายฉบับชาวบ้าน (Policy Localizer)
|
| 319 |
+
</h4>
|
| 320 |
+
<p class="text-xs text-gray-400 mb-4">แปลงภาษาราชการยากๆ ให้เป็นภาษาพูดที่กินใจตามกลุ่มเป้าหมาย</p>
|
| 321 |
+
|
| 322 |
+
<div class="space-y-4">
|
| 323 |
+
<div>
|
| 324 |
+
<label class="text-sm text-gray-300">ใส่นโยบาย (ภาษาราชการ/ทางการ)</label>
|
| 325 |
+
<textarea id="policyInput" rows="2" class="w-full bg-gray-800 border border-gray-600 rounded p-2 text-white" placeholder="เช่น จัดตั้งกองทุนพัฒนาหมู่บ้านละ 2 ล้านบาท เพื่อส่งเสริมวิสาหกิจชุมชน..."></textarea>
|
| 326 |
+
</div>
|
| 327 |
+
<div>
|
| 328 |
+
<label class="text-sm text-gray-300">แปลงสารให้ใครฟัง?</label>
|
| 329 |
+
<select id="policyTarget" class="w-full bg-gray-800 border border-gray-600 rounded p-2 text-white">
|
| 330 |
+
<option value="ผู้เฒ่าผู้แก่ (ภาษาอีสาน จริงใจ)">ผู้เฒ่าผู้แก่ (ภาษาอีสาน)</option>
|
| 331 |
+
<option value="วัยรุ่น (สั้น กระชับ ทันสมัย)">วัยรุ่น First Voter</option>
|
| 332 |
+
<option value="พ่อค้าแม่ค้า (เน้นกำไร ปากท้อง)">พ่อค้าแม่ค้า</option>
|
| 333 |
+
</select>
|
| 334 |
+
</div>
|
| 335 |
+
<button id="btnTranslatePolicy" class="w-full bg-yellow-600 hover:bg-yellow-700 text-white font-bold py-2 px-4 rounded transition">
|
| 336 |
+
✨ แปลงเป็นภาษาโดนใจ
|
| 337 |
+
</button>
|
| 338 |
</div>
|
| 339 |
+
<div id="policyOutput" class="hidden mt-4 p-4 bg-gray-900 rounded border border-gray-700 text-sm whitespace-pre-wrap text-yellow-100 font-medium"></div>
|
| 340 |
</div>
|
|
|
|
| 341 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 342 |
</div>
|
| 343 |
+
</section>
|
| 344 |
+
|
| 345 |
+
<!-- Competitor Analysis -->
|
| 346 |
+
<section>
|
| 347 |
+
<div class="mb-6 border-b-2 border-purple-200 pb-4">
|
| 348 |
+
<h3 class="text-3xl font-bold text-gray-800">⚡ วิเคราะห์จุดแข็ง-จุดอ่อน (SWOT)</h3>
|
| 349 |
+
<p class="text-gray-600 mt-2">
|
| 350 |
+
เปรียบเทียบศักยภาพ "ธนอนันต์ (กล้าธรรม)" vs "เจ้าของพื้นที่เดิม" vs "กระแสพรรคประชาชน"
|
| 351 |
+
</p>
|
| 352 |
</div>
|
| 353 |
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-8">
|
| 354 |
+
<div class="info-card">
|
| 355 |
+
<h4 class="text-xl font-bold text-gray-700 mb-4 text-center">สมรภูมิความนิยม (Radar Chart)</h4>
|
| 356 |
+
<div class="chart-container">
|
| 357 |
+
<canvas id="radarChart"></canvas>
|
|
|
|
|
|
|
| 358 |
</div>
|
|
|
|
| 359 |
</div>
|
| 360 |
+
<div class="info-card flex flex-col justify-center bg-purple-50">
|
| 361 |
+
<h4 class="text-xl font-bold text-purple-800 mb-4">จุดยุทธศาสตร์ของ ธนอนันต์:</h4>
|
| 362 |
+
<ul class="space-y-4">
|
| 363 |
+
<li class="flex items-start">
|
| 364 |
+
<span class="text-2xl mr-3">🏛️</span>
|
| 365 |
+
<div>
|
| 366 |
+
<strong class="text-gray-900">ฐานเสียงตระกูล (Legacy):</strong>
|
| 367 |
+
<span class="text-gray-600 text-sm block">ชื่อชั้น "เมนะสวัสดิ์" ยังขลังในกลุ่มผู้สูงอายุ ต้องรักษาไว้ห้ามหลุด</span>
|
| 368 |
+
</div>
|
| 369 |
+
</li>
|
| 370 |
+
<li class="flex items-start">
|
| 371 |
+
<span class="text-2xl mr-3">🚜</span>
|
| 372 |
+
<div>
|
| 373 |
+
<strong class="text-gray-900">นโยบายกล้าธรรม (Policy):</strong>
|
| 374 |
+
<span class="text-gray-600 text-sm block">ชูจุดขาย "เปลี่ยนที่ ส.ป.ก. เป็นโฉนด" และ "น้ำแก้จน" ซึ่งโดนใจคนพื้นที่อุดรฯ เขต 6 มากที่สุด</span>
|
| 375 |
+
</div>
|
| 376 |
+
</li>
|
| 377 |
+
<li class="flex items-start">
|
| 378 |
+
<span class="text-2xl mr-3">📲</span>
|
| 379 |
+
<div>
|
| 380 |
+
<strong class="text-gray-900">Digital Gap (ช่องว่าง):</strong>
|
| 381 |
+
<span class="text-gray-600 text-sm block">คู่แข่งแชมป์เก่ายังอ่อนเรื่อง TikTok นี่คือโอกาสเจาะกลุ่ม Young Voter 18-25 ปี</span>
|
| 382 |
+
</div>
|
| 383 |
+
</li>
|
| 384 |
+
</ul>
|
| 385 |
</div>
|
| 386 |
</div>
|
| 387 |
+
</section>
|
| 388 |
+
|
| 389 |
+
<!-- Timeline Roadmap -->
|
| 390 |
+
<section class="bg-white p-6 rounded-2xl shadow-lg border-t-4 border-purple-600">
|
| 391 |
+
<h3 class="text-2xl font-bold text-gray-800 mb-6">📅 ปฏิทินปฏิบัติการ 90 วันก่อนเลือกตั้ง (2569)</h3>
|
| 392 |
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-6">
|
| 393 |
+
<!-- Phase 1 -->
|
| 394 |
+
<div class="relative pl-6 border-l-4 border-gray-200">
|
| 395 |
+
<div class="absolute -left-[10px] top-0 timeline-dot bg-gray-300"></div>
|
| 396 |
+
<h4 class="font-bold text-lg text-gray-700">เดือนที่ 1: "ปลุกยักษ์"</h4>
|
| 397 |
+
<span class="text-xs font-semibold bg-gray-200 text-gray-600 px-2 py-1 rounded">Awareness</span>
|
| 398 |
+
<ul class="mt-3 text-sm text-gray-600 space-y-2 list-disc list-inside">
|
| 399 |
+
<li>เปิดตัวเพจ "ธนอนันต์ อุดรยุคใหม่"</li>
|
| 400 |
+
<li>ยิง Ads แนะนำตัวเจาะรายตำบล</li>
|
| 401 |
+
<li>เปิดศูนย์ประสานงานพรรคกล้าธรรม</li>
|
| 402 |
+
</ul>
|
| 403 |
</div>
|
| 404 |
+
<!-- Phase 2 -->
|
| 405 |
+
<div class="relative pl-6 border-l-4 border-purple-300">
|
| 406 |
+
<div class="absolute -left-[10px] top-0 timeline-dot bg-purple-400"></div>
|
| 407 |
+
<h4 class="font-bold text-lg text-purple-800">เดือนที่ 2: "กล้าชน"</h4>
|
| 408 |
+
<span class="text-xs font-semibold bg-purple-100 text-purple-600 px-2 py-1 rounded">Engagement</span>
|
| 409 |
+
<ul class="mt-3 text-sm text-gray-600 space-y-2 list-disc list-inside">
|
| 410 |
+
<li>เปิดเวทีปราศรัยย่อย 20 จุด</li>
|
| 411 |
+
<li>Challenge TikTok "ปัญหาบ้านเฮา"</li>
|
| 412 |
+
<li>ระดม อสม. เคาะประตูบ้าน</li>
|
| 413 |
+
</ul>
|
| 414 |
</div>
|
| 415 |
+
<!-- Phase 3 -->
|
| 416 |
+
<div class="relative pl-6 border-l-4 border-purple-600">
|
| 417 |
+
<div class="absolute -left-[10px] top-0 timeline-dot bg-purple-700 animate-pulse"></div>
|
| 418 |
+
<h4 class="font-bold text-lg text-purple-900">เดือนที่ 3: "ปิดกล่อง"</h4>
|
| 419 |
+
<span class="text-xs font-semibold bg-purple-600 text-white px-2 py-1 rounded">Conversion</span>
|
| 420 |
+
<ul class="mt-3 text-sm text-gray-600 space-y-2 list-disc list-inside">
|
| 421 |
+
<li>ปราศรัยใหญ่ นำโดยหัวหน้าพรรค</li>
|
| 422 |
+
<li>ปล่อยคลิปไวรัลโค้งสุดท้าย</li>
|
| 423 |
+
<li>SMS/Line ย้ำเบอร์เช้าวันเลือกตั้ง</li>
|
| 424 |
+
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 425 |
</div>
|
| 426 |
</div>
|
| 427 |
+
</section>
|
| 428 |
|
| 429 |
+
<!-- Footer -->
|
| 430 |
+
<footer class="text-center py-8 text-gray-500 text-sm mt-8 border-t">
|
| 431 |
+
<p>© 2026 Kla Tham Party Strategic Center (Udon Thani D6). All Rights Reserved.</p>
|
| 432 |
+
<p>ระบบจำลองยุทธศาสตร์การเลือกตั้ง | Powered by Google Gemini</p>
|
| 433 |
+
</footer>
|
| 434 |
|
| 435 |
</main>
|
| 436 |
|
| 437 |
+
<!-- JS Logic -->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 438 |
<script type="module">
|
| 439 |
import { GoogleGenerativeAI } from "@google/generative-ai";
|
| 440 |
|
| 441 |
+
// --- GEMINI API SETUP ---
|
| 442 |
+
const apiKey = "AIzaSyBlvdz3wUNm2PtiuYnN2al9L7krngami-E";
|
| 443 |
const genAI = new GoogleGenerativeAI(apiKey);
|
| 444 |
const model = genAI.getGenerativeModel({ model: "gemini-2.5-flash-preview-09-2025" });
|
| 445 |
|
| 446 |
+
function setLoading(btnId, outputId, isLoading, loadingText = "AI กำลังคิด...") {
|
| 447 |
+
const btn = document.getElementById(btnId);
|
| 448 |
+
const output = document.getElementById(outputId);
|
| 449 |
+
if (isLoading) {
|
| 450 |
+
btn.disabled = true;
|
| 451 |
+
btn.classList.add('opacity-70', 'cursor-not-allowed');
|
| 452 |
+
if (!btn.dataset.originalText) btn.dataset.originalText = btn.innerHTML;
|
| 453 |
+
btn.innerHTML = `<span class="loader border-white/50 border-t-white mr-2" style="width:16px;height:16px;"></span> ${loadingText}`;
|
| 454 |
+
if(output) {
|
| 455 |
+
output.classList.remove('hidden');
|
| 456 |
+
// Only set text if output is empty or needs reset, otherwise keep structure
|
| 457 |
+
if(output.innerText === "") output.textContent = '... กำลังประมวลผล ...';
|
| 458 |
+
}
|
| 459 |
+
} else {
|
| 460 |
+
btn.disabled = false;
|
| 461 |
+
btn.classList.remove('opacity-70', 'cursor-not-allowed');
|
| 462 |
+
btn.innerHTML = btn.dataset.originalText;
|
| 463 |
}
|
| 464 |
}
|
| 465 |
|
| 466 |
+
// Feature 1: Social Caption Generator
|
| 467 |
+
document.getElementById('btnGenerateCaption').addEventListener('click', async () => {
|
| 468 |
+
const topic = document.getElementById('captionTopic').value;
|
| 469 |
+
const platform = document.getElementById('captionPlatform').value;
|
| 470 |
+
const outputDiv = document.getElementById('captionOutput');
|
|
|
|
|
|
|
|
|
|
|
|
|
| 471 |
|
| 472 |
+
if (!topic.trim()) { alert("กรุณาใส่หัวข้อคอนเทนต์ครับ"); return; }
|
| 473 |
+
setLoading('btnGenerateCaption', 'captionOutput', true);
|
|
|
|
|
|
|
| 474 |
|
| 475 |
try {
|
| 476 |
+
const prompt = `
|
| 477 |
+
คุณคือทีมสื่อสารของ 'ธนอนันต์ เมนะสวัสดิ์' ผู้สมัคร ส.ส. อุดรธานี เขต 6 พรรคกล้าธรรม
|
| 478 |
+
Identity: ลูกหลานคนอุดร, จริงใจ, กล้าทำจริง (สไตล์พรรคกล้าธรรม), เข้าถึงง่าย
|
| 479 |
+
|
| 480 |
+
เขียน Caption สำหรับแพลตฟอร์ม: ${platform}
|
| 481 |
+
หัวข้อ: "${topic}"
|
| 482 |
+
|
| 483 |
+
ข้อกำหนด:
|
| 484 |
+
- ถ้าเป็น TikTok: ขอสั้นๆ กระชับ ภาษาอีสานวัยรุ่น ติดแฮชแท็กฮิต
|
| 485 |
+
- ถ้าเป็น Facebook: ขอแบบเล่าเรื่อง เห็นภาพความทุ่มเท ภาษาทางการกึ่งกันเอง
|
| 486 |
+
- ถ้าเป็น Line OA: ขอแบบสั้นๆ เหมือนทักทายญาติพี่น้อง แจ้งข่าวสารชัดเจน
|
| 487 |
+
- ต้องมีคำว่า "กล้าธรรม" หรือ "ธนอนันต์" ในข้อความ
|
| 488 |
+
`;
|
| 489 |
+
|
| 490 |
const result = await model.generateContent(prompt);
|
| 491 |
+
const response = await result.response;
|
| 492 |
+
outputDiv.innerHTML = `<strong>📲 Draft Caption (${platform}):</strong><br><br>${response.text().replace(/\n/g, '<br>')}`;
|
| 493 |
} catch (error) {
|
| 494 |
+
outputDiv.textContent = "AI Error: " + error.message;
|
| 495 |
} finally {
|
| 496 |
+
setLoading('btnGenerateCaption', 'captionOutput', false);
|
|
|
|
| 497 |
}
|
| 498 |
+
});
|
|
|
|
|
|
|
| 499 |
|
| 500 |
+
// Feature 2: Crisis Strategy
|
| 501 |
+
document.getElementById('btnGenerateStrategy').addEventListener('click', async () => {
|
| 502 |
+
const situation = document.getElementById('crisisInput').value;
|
| 503 |
+
const outputDiv = document.getElementById('strategyOutput');
|
|
|
|
| 504 |
|
| 505 |
+
if (!situation.trim()) { alert("ระบุสถานการณ์ก่อนครับ"); return; }
|
| 506 |
+
setLoading('btnGenerateStrategy', 'strategyOutput', true);
|
| 507 |
+
|
| 508 |
+
try {
|
| 509 |
+
const prompt = `
|
| 510 |
+
สถานการณ์ด่วน! ผู้สมัคร 'ธนอนันต์ พรรคกล้าธรรม' เจอเรื่อง: "${situation}"
|
| 511 |
+
ขอแผนรับมือ 3 ขั้นตอนด่วน (Immediate Action, Message, Follow-up)
|
| 512 |
+
สไตล์: กล้าชนแต่ไม่ก้าวร้าว, ใช้ความจริงสู้, รักษาฐานเสียง
|
| 513 |
+
`;
|
| 514 |
+
const result = await model.generateContent(prompt);
|
| 515 |
+
outputDiv.innerHTML = `<strong>🛡️ แผนแก้เกมด่วน:</strong><br><br>${result.response.text().replace(/\n/g, '<br>')}`;
|
| 516 |
+
} catch (error) {
|
| 517 |
+
outputDiv.textContent = "Error: " + error.message;
|
| 518 |
+
} finally {
|
| 519 |
+
setLoading('btnGenerateStrategy', 'strategyOutput', false);
|
| 520 |
+
}
|
| 521 |
});
|
| 522 |
|
| 523 |
+
// Feature 3: Debate Simulator - Step 1: Generate Question
|
| 524 |
+
document.getElementById('btnStartDebate').addEventListener('click', async () => {
|
| 525 |
+
const topic = document.getElementById('debateTopic').value;
|
| 526 |
+
const questionDiv = document.getElementById('debateQuestionText');
|
| 527 |
+
const section = document.getElementById('debateQuestionSection');
|
| 528 |
|
| 529 |
+
// Reset previous state
|
| 530 |
+
section.classList.remove('hidden');
|
| 531 |
+
questionDiv.innerHTML = "กำลังคิดคำถามโหดๆ...";
|
| 532 |
+
document.getElementById('debateAnswer').value = "";
|
| 533 |
+
document.getElementById('debateFeedback').classList.add('hidden');
|
| 534 |
|
| 535 |
+
setLoading('btnStartDebate', null, true, "กำลังลับฝีปาก...");
|
| 536 |
+
|
| 537 |
+
try {
|
| 538 |
+
const prompt = `
|
| 539 |
+
Act as a tough political debate moderator or an aggressive opponent.
|
| 540 |
+
Target: Thanon Anant (Kla Tham Party candidate in Udon Thani).
|
| 541 |
+
Topic: ${topic}.
|
| 542 |
+
|
| 543 |
+
Generate ONE tough, provocative question in Thai (ภาษาไทย).
|
| 544 |
+
The question should attack the party's weak points or challenge the feasibility of the policy.
|
| 545 |
+
Make it short and sharp (max 2 sentences).
|
| 546 |
+
`;
|
| 547 |
+
const result = await model.generateContent(prompt);
|
| 548 |
+
questionDiv.innerText = result.response.text();
|
| 549 |
+
} catch (error) {
|
| 550 |
+
questionDiv.innerText = "Error generating question.";
|
| 551 |
+
} finally {
|
| 552 |
+
setLoading('btnStartDebate', null, false);
|
| 553 |
+
}
|
| 554 |
});
|
| 555 |
|
| 556 |
+
// Feature 3: Debate Simulator - Step 2: Grade Answer
|
| 557 |
+
document.getElementById('btnGradeAnswer').addEventListener('click', async () => {
|
| 558 |
+
const question = document.getElementById('debateQuestionText').innerText;
|
| 559 |
+
const answer = document.getElementById('debateAnswer').value;
|
| 560 |
+
const feedbackDiv = document.getElementById('debateFeedback');
|
| 561 |
|
| 562 |
+
if (!answer.trim()) { alert("ตอบคำถามก่อนครับท่าน!"); return; }
|
| 563 |
+
setLoading('btnGradeAnswer', 'debateFeedback', true, "กรรมการกำลังให้คะแนน...");
|
| 564 |
+
|
| 565 |
+
try {
|
| 566 |
+
const prompt = `
|
| 567 |
+
Context: Political Debate Training for Thanon Anant (Kla Tham Party).
|
| 568 |
+
Question: "${question}"
|
| 569 |
+
Candidate's Answer: "${answer}"
|
| 570 |
+
|
| 571 |
+
Please evaluate this answer in Thai:
|
| 572 |
+
1. Score (out of 10).
|
| 573 |
+
2. Strengths (จุดดี).
|
| 574 |
+
3. Weaknesses (จุดด้อย).
|
| 575 |
+
4. Suggested Improvement (แนะนำวิธีตอบให้คมขึ้น/ดีขึ้น).
|
| 576 |
+
`;
|
| 577 |
+
const result = await model.generateContent(prompt);
|
| 578 |
+
feedbackDiv.innerHTML = `<strong>📝 ผลการประเมิน:</strong><br><br>${result.response.text().replace(/\n/g, '<br>')}`;
|
| 579 |
+
} catch (error) {
|
| 580 |
+
feedbackDiv.textContent = "Error: " + error.message;
|
| 581 |
+
} finally {
|
| 582 |
+
setLoading('btnGradeAnswer', 'debateFeedback', false);
|
| 583 |
+
}
|
| 584 |
});
|
| 585 |
|
| 586 |
+
// Feature 4: Policy Localizer
|
| 587 |
+
document.getElementById('btnTranslatePolicy').addEventListener('click', async () => {
|
| 588 |
+
const policy = document.getElementById('policyInput').value;
|
| 589 |
+
const target = document.getElementById('policyTarget').value;
|
| 590 |
+
const outputDiv = document.getElementById('policyOutput');
|
| 591 |
+
|
| 592 |
+
if (!policy.trim()) { alert("ใส่นโยบายมาก่อนครับ"); return; }
|
| 593 |
+
setLoading('btnTranslatePolicy', 'policyOutput', true);
|
| 594 |
+
|
| 595 |
+
try {
|
| 596 |
+
const prompt = `
|
| 597 |
+
คุณคือผู้เชี่ยวชาญด้านการสื่อสารการเมืองท้องถิ่นอุดรธานี
|
| 598 |
+
จงแปลงนโยบายภาษาราชการนี้: "${policy}"
|
| 599 |
+
|
| 600 |
+
ให้เป็นภาษาพูดที่โดนใจกลุ่มเป้าหมาย: "${target}"
|
| 601 |
+
|
| 602 |
+
Guideline:
|
| 603 |
+
- ถ้าเป็นผู้เฒ่าผู้แก่: ใช้ภาษาอีสาน คำผญา เปรียบเปรยให้เห็นภาพ
|
| 604 |
+
- ถ้าเป็นวัยรุ่น: ใช้ภาษาทันสมัย สั้นๆ เหมือน Twitter/TikTok
|
| 605 |
+
- ถ้าเป็นพ่อค้าแม่ค้า: เน้นตัวเลข กำไร ความคุ้มค่า
|
| 606 |
+
|
| 607 |
+
ขอผลลัพธ์สั้นๆ (ไม่เกิน 3 บรรทัด) แต่ทรงพลัง
|
| 608 |
+
`;
|
| 609 |
+
const result = await model.generateContent(prompt);
|
| 610 |
+
outputDiv.innerHTML = `"${result.response.text()}"`;
|
| 611 |
+
} catch (error) {
|
| 612 |
+
outputDiv.textContent = "Error: " + error.message;
|
| 613 |
+
} finally {
|
| 614 |
+
setLoading('btnTranslatePolicy', 'policyOutput', false);
|
| 615 |
+
}
|
| 616 |
+
});
|
| 617 |
+
|
| 618 |
+
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 619 |
|
| 620 |
+
<!-- CHART JS -->
|
| 621 |
+
<script>
|
| 622 |
+
const commonTooltip = {
|
| 623 |
+
callbacks: {
|
| 624 |
+
title: function(tooltipItems) { return tooltipItems[0].chart.data.labels[tooltipItems[0].dataIndex]; }
|
| 625 |
+
}
|
| 626 |
+
};
|
| 627 |
+
|
| 628 |
+
// 1. Social Media Share of Voice
|
| 629 |
+
const ctxSocial = document.getElementById('socialChart').getContext('2d');
|
| 630 |
+
new Chart(ctxSocial, {
|
| 631 |
+
type: 'doughnut',
|
| 632 |
+
data: {
|
| 633 |
+
labels: ['TikTok (Gen Z/Y)', 'Facebook (Gen X/Boomer)', 'Line OA (Community Leaders)', 'YouTube/Others'],
|
| 634 |
+
datasets: [{
|
| 635 |
+
data: [45, 30, 20, 5],
|
| 636 |
+
backgroundColor: ['#000000', '#1877F2', '#00B900', '#FF0000'],
|
| 637 |
+
borderWidth: 2
|
| 638 |
+
}]
|
| 639 |
+
},
|
| 640 |
+
options: {
|
| 641 |
+
responsive: true,
|
| 642 |
+
maintainAspectRatio: false,
|
| 643 |
+
plugins: { legend: { position: 'right' } }
|
| 644 |
+
}
|
| 645 |
+
});
|
| 646 |
+
|
| 647 |
+
// 2. Competitor Radar
|
| 648 |
+
const ctxRadar = document.getElementById('radarChart').getContext('2d');
|
| 649 |
+
new Chart(ctxRadar, {
|
| 650 |
+
type: 'radar',
|
| 651 |
+
data: {
|
| 652 |
+
labels: ['ความนิยมส่วนตัว', 'นโยบาย (ที่ดิน/น้ำ)', 'กระแสพรรค', 'ทีมงานพื้นที่', 'งบ/ทรัพยากร'],
|
| 653 |
+
datasets: [{
|
| 654 |
+
label: 'ธนอนันต์ (กล้าธรรม)',
|
| 655 |
+
data: [75, 95, 70, 85, 90],
|
| 656 |
+
borderColor: '#6A0DAD',
|
| 657 |
+
backgroundColor: 'rgba(106, 13, 173, 0.2)',
|
| 658 |
+
pointBackgroundColor: '#6A0DAD'
|
| 659 |
+
}, {
|
| 660 |
+
label: 'คู่แข่ง (เพื่อไทยเดิม)',
|
| 661 |
+
data: [90, 70, 85, 80, 80],
|
| 662 |
+
borderColor: '#FF0000',
|
| 663 |
+
backgroundColor: 'rgba(255, 0, 0, 0.1)',
|
| 664 |
+
borderDash: [5, 5]
|
| 665 |
+
}]
|
| 666 |
+
},
|
| 667 |
+
options: {
|
| 668 |
+
responsive: true,
|
| 669 |
+
maintainAspectRatio: false,
|
| 670 |
+
scales: { r: { suggestedMin: 0, suggestedMax: 100 } }
|
| 671 |
+
}
|
| 672 |
+
});
|
| 673 |
</script>
|
| 674 |
</body>
|
| 675 |
</html>
|