index.html 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550
  1. <!DOCTYPE html>
  2. <html lang="es">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <title>Biergarten Klein</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <!-- Meta tags para evitar cache -->
  8. <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
  9. <meta http-equiv="Pragma" content="no-cache">
  10. <meta http-equiv="Expires" content="0">
  11. <!-- Fuentes + Tailwind -->
  12. <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  13. <link rel="stylesheet" as="style" onload="this.rel='stylesheet'"
  14. href="https://fonts.googleapis.com/css2?display=swap&family=Noto+Sans:wght@400;500;700;900&family=Spline+Sans:wght@400;500;700">
  15. <link rel="stylesheet" href="express/animations.css">
  16. <link rel="stylesheet" href="express/styles.css">
  17. <link rel="stylesheet" href="express/tlw.css">
  18. <script src="express/js/app.js" type="module"></script>
  19. </head>
  20. <body class="h-[100dvh] max-h-[100dvh] flex flex-col bg-gray-50 overflow-x-hidden"
  21. style='font-family:"Spline Sans","Noto Sans",sans-serif;'>
  22. <!-- ---------- HEADER ---------- -->
  23. <header class="flex-col top-0 inset-x-0 z-10 bg-gray-50 p-2 flex justify-center items-center border-b border-gray-200">
  24. <h1 id="mainTitle" class="text-[26px] font-bold text-[#101419] tracking-tight">
  25. Biergarten Klein
  26. </h1>
  27. </header>
  28. <!-- ---------- MAIN ---------- -->
  29. <main class="relative flex-1 flex flex-col min-h-0 overflow-x-hidden">
  30. <!-- ===== MENÚ tab ===== -->
  31. <section id="menuTab" data-index="0" class="min-h-0 overflow-y-auto h-full" data-tab>
  32. <div class="pt-4 pb-3">
  33. <!-- Barra de progreso para cerveza gratis -->
  34. <div class="mx-4 mb-6 p-4 bg-gradient-to-r from-amber-50 to-orange-50 rounded-xl border border-amber-200">
  35. <div class="flex items-center justify-between mb-2">
  36. <div class="flex items-center gap-2">
  37. <span class="text-lg">🍺</span>
  38. <span class="text-sm font-semibold text-amber-800">¡Cerveza gratis al 100%!</span>
  39. </div>
  40. <span id="progressText" class="text-sm font-bold text-amber-700">100%</span>
  41. </div>
  42. <div class="relative w-full h-3 bg-amber-100 rounded-full overflow-hidden shadow-inner">
  43. <!-- Barra de progreso animada -->
  44. <div id="progressBar" class="h-full bg-gradient-to-r from-amber-400 to-orange-500 rounded-full transition-all duration-500 ease-out shadow-sm relative overflow-hidden" style="width: 100%">
  45. <!-- Efecto de brillo -->
  46. <div class="absolute inset-0 bg-gradient-to-r from-transparent via-white/30 to-transparent skew-x-12 animate-pulse"></div>
  47. </div>
  48. <!-- Indicador de meta -->
  49. <div class="absolute right-1 top-1/2 transform -translate-y-1/2">
  50. <div class="w-2 h-2 bg-amber-600 rounded-full border border-white shadow-sm"></div>
  51. </div>
  52. </div>
  53. <div class="flex items-center justify-between mt-2">
  54. <span class="text-xs text-amber-700">Cada compra suma puntos</span>
  55. <button id="rewardBtn" class="text-xs bg-amber-500 hover:bg-amber-600 text-white px-3 py-1 rounded-full font-medium transition-colors duration-200 opacity-50 cursor-not-allowed" disabled>
  56. 🎉 ¡Reclamar!
  57. </button>
  58. </div>
  59. </div>
  60. </div>
  61. <div class="px-4 overflow-y-auto">
  62. <input type="text" id="searchInput" placeholder="Buscar..." class="w-full px-4 py-2 mb-4 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#101419]">
  63. <ul id="productList" class="space-y-6">
  64. </ul>
  65. </div>
  66. <template id="product-card-template">
  67. <li class="flex items-stretch justify-between gap-4 rounded-xl">
  68. <div class="flex flex-[2_2_0px] flex-col gap-4">
  69. <div class="flex flex-col gap-1">
  70. <p class="product-type text-[#58728d] text-sm"></p>
  71. <p class="product-name text-[#101419] text-base font-bold leading-tight"></p>
  72. <p class="product-description text-[#58728d] text-sm"></p>
  73. </div>
  74. <div class="flex items-center gap-3">
  75. <button class="add-to-cart-btn flex items-center gap-1 w-fit h-8 px-3 rounded-full bg-[#101419] hover:bg-[#37404a] text-white text-sm font-medium">
  76. <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="16" height="16" fill="currentColor">
  77. <path d="M12 5v14m7-7H5" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
  78. </svg>
  79. Añadir
  80. </button>
  81. <span class="product-price text-sm font-semibold text-[#101419]"></span>
  82. </div>
  83. </div>
  84. <div class="product-image flex-1 aspect-video bg-cover bg-center rounded-xl"></div>
  85. </li>
  86. </template>
  87. </section>
  88. <!-- ===== CHAT ===== -->
  89. <section id="chatTab" data-index="2" data-tab class="flex hidden flex-col h-full flex-1 min-h-0">
  90. <!-- Contenedor de mensajes que puede crecer y hacer scroll -->
  91. <div id="chatContainer" class="flex flex-col h-full flex-1 bg-white border border-gray-200 rounded-xl shadow-sm m-4 overflow-hidden">
  92. <header>
  93. <div class="flex items-center justify-between px-4 py-3 border-b border-gray-200 bg-gray-50">
  94. <div id="onlineUsers" class="flex items-center gap-3"><span class="rounded-full bg-lime-500 w-2 h-2 inline-block shadow-md shadow-lime-300"></span><h4>4 Usuarios en linea</h4></div>
  95. </div>
  96. </header>
  97. <!-- Mensajes -->
  98. <div id="chatMessages" class="flex-1 overflow-y-auto px-4 py-3 space-y-1 bg-gray-50 font-mono text-sm">
  99. <!-- Mensajes de ejemplo estilo IRC -->
  100. <template id="chatMessageTemplate">
  101. <div class="chat-message"><span class="text-gray-400 chat-message-time">[00:36]</span> <span class="font-bold chat-message-user">&lt;JuanP_mesa5&gt;</span> <span class="chat-message-text">Yo también quiero!</span></div>
  102. </template>
  103. <template id="systemMessageTemplate">
  104. <div class="system-container"><span class="text-gray-400 chat-message-time">[14:24]</span> <span class="font-bold chat-message-text">*** Maria_mesa2 se ha unido al chat</span></div>
  105. </template>
  106. </div>
  107. <!-- Input y botón -->
  108. <form id="chatForm" class="flex flex-col relative gap-2 border-t border-gray-200 bg-white px-3 py-2" autocomplete="off">
  109. <ul id="userList" class="hidden absolute bottom-full w-3/4 rounded-lg border bg-gray-100 flex flex-col gap-2 py-2 px-2">
  110. </ul>
  111. <div class="flex gap-2 w-full">
  112. <input id="chatInput" type="text" placeholder="Escribe un mensaje..." class="flex-grow flex-1 px-4 py-2 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-[#101419] text-sm bg-gray-50" autocomplete="off" maxlength="300" />
  113. <button id="chatSubmitButton" type="submit" class="bg-blue-500 flex-shrink text-white px-4 py-2 rounded-lg font-medium transition-colors duration-200">Enviar</button>
  114. </div>
  115. </form>
  116. </div>
  117. </section>
  118. <!-- ===== CARRITO ===== -->
  119. <section id="cartTab" data-tab data-index="1" class="flex flex-col hidden flex-1 min-h-0">
  120. <header class="p-4 border-b border-gray-200">
  121. <h3 class="text-lg font-bold text-[#101419]">Tu pedido</h3>
  122. </header>
  123. <div id="cartItems" class="flex-1 overflow-y-auto p-4 space-y-2 max-h-[25vh]"></div>
  124. <p id="emptyCartText" class="hidden text-center text-gray-400 mt-4">Tu carrito está vacío.</p>
  125. <footer class="p-4 border-t border-gray-200 space-y-3">
  126. <div class="flex justify-between text-base">
  127. <span>Total:</span>
  128. <span id="cartTotal">$0</span>
  129. </div>
  130. <button id="checkoutButton"
  131. class="w-full bg-[#101419] hover:bg-[#37404a] disabled:opacity-50 text-white py-2 rounded-md"
  132. disabled>
  133. Envia tu orden
  134. </button>
  135. </footer>
  136. <div class="max-w-4xl mx-auto bg-white rounded-xl shadow-sm border border-gray-200 overflow-hidden">
  137. <!-- Header con nombre de usuario -->
  138. <div class="bg-gray-50 px-6 py-2 border-b border-gray-200">
  139. <h2 id="usernameTable" class="text-[19px] font-bold text-[#101419]">Pedido de Juan Pérez</h2>
  140. </div>
  141. <div class="overflow-x-auto max-h-[20vh]">
  142. <table id="historyTable" class="w-full">
  143. <thead class="bg-gray-50 border-b border-gray-200">
  144. <tr>
  145. <th class="px-6 py-3 text-left text-sm font-bold text-[#101419]">Cantidad</th>
  146. <th class="px-6 py-3 text-left text-sm font-bold text-[#101419]">Producto</th>
  147. <th class="px-6 py-3 text-right text-sm font-bold text-[#101419]">Precio</th>
  148. </tr>
  149. </thead>
  150. <tbody class="divide-y divide-gray-200">
  151. <template id="historyRowTemplate">
  152. <tr class="hover:bg-gray-50 transition-colors">
  153. <td class="list-element-quantity px-6 py-4 text-sm text-[#58728d]">1</td>
  154. <td class="px-6 py-4">
  155. <div class="flex flex-col">
  156. <span class="list-element-name text-sm font-medium text-[#101419]">Klein Lager</span>
  157. </div>
  158. </td>
  159. <td class="list-element-price px-6 py-4 text-sm font-semibold text-[#101419] text-right">$6.000</td>
  160. </tr>
  161. </template>
  162. </tbody>
  163. <!-- Total -->
  164. <tfoot class="bg-gray-50 border-t border-gray-200">
  165. <tr>
  166. <td colspan="2" class="px-6 py-4 text-base font-bold text-[#101419] text-right">
  167. Total General:
  168. </td>
  169. <td id="cartHistoryTotal" class="px-6 py-4 text-lg font-bold text-[#101419] text-right">
  170. $0
  171. </td>
  172. </tr>
  173. </tfoot>
  174. </table>
  175. </div>
  176. </div>
  177. </section>
  178. </main>
  179. <!-- ---------- NAVBAR ---------- -->
  180. <footer class="inset-x-0 z-10 border-t border-gray-200 bg-gray-50 px-4 py-2">
  181. <nav class="flex gap-2">
  182. <button data-target="menuTab" data-title="Biergarten Klein" class="active tab-btn flex-1 flex flex-col items-center text-[#58728d]">
  183. <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="h-8"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M5 12l-2 0l9 -9l9 9l-2 0" /><path d="M5 12v7a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-7" /><path d="M9 21v-6a2 2 0 0 1 2 -2h2a2 2 0 0 1 2 2v6" /></svg><span class="text-xs font-medium">Inicio</span>
  184. </button>
  185. <button data-target="cartTab" data-title="Carrito Klein" class="tab-btn flex-1 flex flex-col items-center text-[#58728d]">
  186. <div id="cartIcon">
  187. <span id="cartCount">0</span>
  188. <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor"
  189. viewBox="0 0 256 256" class="h-8">
  190. <path
  191. d="M222.14,58.87A8,8,0,0,0,216,56H54.68L49.79,29.14A16,16,0,0,0,34.05,16H16a8,8,0,0,0,0,16h18L59.56,172.29a24,24,0,0,0,5.33,11.27,28,28,0,1,0,44.4,8.44h45.42A27.75,27.75,0,0,0,152,204a28,28,0,1,0,28-28H83.17a8,8,0,0,1-7.87-6.57L72.13,152h116a24,24,0,0,0,23.61-19.71l12.16-66.86A8,8,0,0,0,222.14,58.87ZM96,204a12,12,0,1,1-12-12A12,12,0,0,1,96,204Zm96,0a12,12,0,1,1-12-12A12,12,0,0,1,192,204Zm4-74.57A8,8,0,0,1,188.1,136H69.22L57.59,72H206.41Z" />
  192. </svg>
  193. </div>
  194. <span class="text-xs font-medium">Carrito</span>
  195. </button>
  196. <button data-target="chatTab" data-title="RetroChat" class="tab-btn flex-1 flex flex-col items-center text-[#58728d]">
  197. <div id="chatIcon">
  198. <span class="hidden"></span>
  199. <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="h-8"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M8 9h8" /><path d="M8 13h6" /><path d="M18 4a3 3 0 0 1 3 3v8a3 3 0 0 1 -3 3h-5l-5 3v-3h-2a3 3 0 0 1 -3 -3v-8a3 3 0 0 1 3 -3h12z" /></svg>
  200. </div><span class="text-xs font-medium">Chat IA</span>
  201. </button>
  202. </nav>
  203. </footer>
  204. <!-- ---------- TOAST ---------- -->
  205. <div id="toastCart"
  206. class="fixed top-4 left-1/2 -translate-x-1/2 bg-[#101419] text-white text-sm
  207. rounded-md px-4 py-2 shadow-lg opacity-0 pointer-events-none z-50
  208. origin-left">
  209. </div>
  210. <!-- MODALS -->
  211. <!-- === MODAL INICIO DE SESIÓN === -->
  212. <div id="sessionModal"
  213. class="hidden fixed inset-0 bg-black/70 flex items-center justify-center z-40 p-4">
  214. <form id="loginForm" class="bg-white w-full max-w-md p-8 rounded-xl shadow-xl space-y-6">
  215. <div class="text-center">
  216. <h2 id="loginTitle" class="text-2xl font-bold text-gray-900">¡Bienvenido!</h2>
  217. <p id="loginMessage" class="text-sm text-gray-600 mt-2">
  218. Ingresa tus datos para comenzar tu pedido
  219. </p>
  220. </div>
  221. <div class="space-y-4">
  222. <div id="emailInputContainer">
  223. <label for="emailInput" class="block text-sm font-medium text-gray-700 mb-2">
  224. Correo electrónico
  225. </label>
  226. <input id="emailInput"
  227. name="email"
  228. type="email"
  229. class="w-full border border-gray-300 px-4 py-3 rounded-lg focus:ring-2 focus:ring-[#101419] focus:border-transparent outline-none transition-all"
  230. placeholder="tu@email.com"
  231. required />
  232. </div>
  233. <div id="pinInputContainer">
  234. <label for="pinInput" class="block text-sm font-medium text-gray-700 mb-2">
  235. PIN de 4 dígitos
  236. </label>
  237. <input id="pinInput"
  238. name="pin"
  239. type="password"
  240. maxlength="4"
  241. pattern="[0-9]{4}"
  242. class="w-full border border-gray-300 px-4 py-3 rounded-lg focus:ring-2 focus:ring-[#101419] focus:border-transparent outline-none transition-all"
  243. placeholder="••••"
  244. required />
  245. </div>
  246. <div id="tableInputContainer">
  247. <label for="tableInput" class="block text-sm font-medium text-gray-700 mb-2">
  248. Número de mesa
  249. </label>
  250. <input id="tableInput"
  251. name="table"
  252. type="number"
  253. min="1"
  254. class="w-full border border-gray-300 px-4 py-3 rounded-lg focus:ring-2 focus:ring-[#101419] focus:border-transparent outline-none transition-all"
  255. placeholder="Ej: 5"
  256. required />
  257. </div>
  258. </div>
  259. <span id="ErrorLogin" class="hidden text-red-500 text-sm"></span>
  260. <a id="recoveryPIN" href="/recovery" class="block w-full bg-gray-200 text-center text-black py-3 rounded-lg font-medium transition-colors duration-200 focus:ring-2 focus:ring-offset-2 focus:ring-[#101419]" >Olvide mi PIN</a>
  261. <button id="sessionAcceptBtn"
  262. type="submit"
  263. class="w-full bg-[#101419] hover:bg-[#37404a] text-white py-3 rounded-lg font-medium transition-colors duration-200 focus:ring-2 focus:ring-offset-2 focus:ring-[#101419]">
  264. Comenzar pedido
  265. </button>
  266. <button id="logoutBtn"
  267. type="button"
  268. class="w-full hidden bg-gray-100 hover:bg-gray-200 text-gray-700 py-3 rounded-lg font-medium transition-colors duration-200 focus:ring-2 focus:ring-offset-2 focus:ring-gray-300">
  269. Cerrar sesión
  270. </button>
  271. </form>
  272. </div>
  273. <!-- Modal de Términos y Condiciones del Regalo -->
  274. <div id="rewardModal" class="fixed hidden inset-0 bg-black/70 flex items-center justify-center z-50 p-4">
  275. <div class="bg-white w-full max-w-lg max-h-[90vh] rounded-xl shadow-xl overflow-hidden">
  276. <!-- Header -->
  277. <div class="bg-gradient-to-r from-amber-500 to-orange-500 px-6 py-4 text-white">
  278. <div class="flex items-center justify-between">
  279. <div class="flex items-center gap-3">
  280. <span class="text-2xl">🍺</span>
  281. <h2 class="text-xl font-bold">¡Cerveza Gratis!</h2>
  282. </div>
  283. <button id="closeRewardModal" class="text-white/80 hover:text-white text-2xl font-bold transition-colors">
  284. ×
  285. </button>
  286. </div>
  287. </div>
  288. <!-- Content -->
  289. <div class="overflow-y-auto max-h-[60vh] px-6 py-4">
  290. <div class="space-y-4">
  291. <!-- Descripción del premio -->
  292. <div class="bg-amber-50 border border-amber-200 rounded-lg p-4">
  293. <h3 class="font-semibold text-amber-800 mb-2">🎉 ¡Felicitaciones!</h3>
  294. <p class="text-amber-700 text-sm">
  295. Has alcanzado el 100% de progreso y puedes reclamar una cerveza gratis de tu elección.
  296. </p>
  297. </div>
  298. <!-- Términos y Condiciones -->
  299. <div class="space-y-3">
  300. <h4 class="font-bold text-gray-800 text-base">Términos y Condiciones:</h4>
  301. <div class="text-sm text-gray-600 space-y-2">
  302. <div class="flex items-start gap-2">
  303. <span class="text-amber-500 font-bold">•</span>
  304. <p>Válido únicamente en Biergarten Klein para consumo en el local.</p>
  305. </div>
  306. <div class="flex items-start gap-2">
  307. <span class="text-amber-500 font-bold">•</span>
  308. <p>La cerveza gratis debe ser reclamada el mismo día que se alcanza el 100%.</p>
  309. </div>
  310. <div class="flex items-start gap-2">
  311. <span class="text-amber-500 font-bold">•</span>
  312. <p>Aplica para cervezas de barril regulares (no incluye cervezas premium o importadas).</p>
  313. </div>
  314. <div class="flex items-start gap-2">
  315. <span class="text-amber-500 font-bold">•</span>
  316. <p>No acumulable con otras promociones o descuentos.</p>
  317. </div>
  318. <div class="flex items-start gap-2">
  319. <span class="text-amber-500 font-bold">•</span>
  320. <p>El premio no tiene valor en efectivo y no es transferible.</p>
  321. </div>
  322. <div class="flex items-start gap-2">
  323. <span class="text-amber-500 font-bold">•</span>
  324. <p>Biergarten Klein se reserva el derecho de modificar o cancelar esta promoción sin previo aviso.</p>
  325. </div>
  326. <div class="flex items-start gap-2">
  327. <span class="text-amber-500 font-bold">•</span>
  328. <p>Debes ser mayor de 18 años para reclamar bebidas alcohólicas.</p>
  329. </div>
  330. </div>
  331. </div>
  332. <!-- Instrucciones -->
  333. <div class="bg-blue-50 border border-blue-200 rounded-lg p-4">
  334. <h4 class="font-semibold text-blue-800 mb-2">📋 Instrucciones:</h4>
  335. <p class="text-blue-700 text-sm">
  336. Una vez aceptes los términos, se generará un código que deberás mostrar al mesero junto con tu identificación para reclamar tu cerveza gratis.
  337. </p>
  338. </div>
  339. </div>
  340. </div>
  341. <!-- Footer con checkbox y botones -->
  342. <div class="border-t border-gray-200 px-6 py-4 space-y-4">
  343. <!-- Checkbox de aceptación -->
  344. <label class="flex items-start gap-3 cursor-pointer">
  345. <input id="acceptTermsCheckbox" type="checkbox" class="mt-1 w-4 h-4 text-amber-600 bg-gray-100 border-gray-300 rounded focus:ring-amber-500 focus:ring-2">
  346. <span class="text-sm text-gray-700">
  347. He leído y acepto los términos y condiciones para reclamar mi cerveza gratis.
  348. </span>
  349. </label>
  350. <!-- Botones -->
  351. <div class="flex gap-3">
  352. <button id="cancelRewardBtn" class="flex-1 bg-gray-100 hover:bg-gray-200 text-gray-700 py-3 rounded-lg font-medium transition-colors duration-200">
  353. Cancelar
  354. </button>
  355. <button id="claimRewardBtn" class="flex-1 bg-amber-500 hover:bg-amber-600 text-white py-3 rounded-lg font-medium transition-colors duration-200 opacity-50 cursor-not-allowed" disabled>
  356. 🎉 Reclamar Premio
  357. </button>
  358. </div>
  359. </div>
  360. </div>
  361. </div>
  362. <div id="successRewardModal" class="fixed hidden inset-0 bg-black/60 flex items-center justify-center z-50 p-4">
  363. <div class="bg-white w-full max-w-md rounded-xl shadow-xl overflow-hidden">
  364. <!-- Header -->
  365. <div class="bg-[#101419] px-6 py-8 text-white text-center relative">
  366. <!-- Elementos decorativos sutiles -->
  367. <div class="absolute top-3 left-4 text-amber-300 text-lg">✨</div>
  368. <div class="absolute top-4 right-6 text-amber-300 text-sm">🎉</div>
  369. <div class="absolute bottom-3 right-4 text-amber-300 text-sm">💫</div>
  370. <!-- Icono principal -->
  371. <div class="text-6xl mb-3">🍺</div>
  372. <!-- Título -->
  373. <h2 class="text-2xl font-bold mb-2">¡FELICIDADES!</h2>
  374. <div class="bg-white/20 rounded-full px-3 py-1 inline-block">
  375. <p class="text-gray-100 text-sm font-medium">🎁 Premio Reclamado</p>
  376. </div>
  377. </div>
  378. <!-- Content -->
  379. <div class="px-6 py-6 space-y-4">
  380. <!-- Mensaje de bienvenida -->
  381. <div class="text-center">
  382. <div class="bg-gray-50 rounded-lg p-4 border border-gray-200">
  383. <h3 class="text-lg font-bold text-[#101419] mb-1">🍻 ¡Tu cerveza gratis te espera!</h3>
  384. <p class="text-[#58728d] text-sm">Sigue estos pasos para reclamar tu premio</p>
  385. </div>
  386. </div>
  387. <!-- Instrucciones -->
  388. <div class="space-y-3">
  389. <div class="flex items-start gap-3 p-3 bg-gray-50 rounded-lg border border-gray-200">
  390. <div class="bg-[#101419] text-white rounded-full w-7 h-7 flex items-center justify-center text-sm font-bold flex-shrink-0">1</div>
  391. <div class="text-sm">
  392. <div class="font-bold text-[#101419] mb-1">👨‍💼 Espera al mesero</div>
  393. <div class="text-[#58728d]">Este se acercará con tu comprobante de premio</div>
  394. </div>
  395. </div>
  396. <div class="flex items-start gap-3 p-3 bg-gray-50 rounded-lg border border-gray-200">
  397. <div class="bg-[#101419] text-white rounded-full w-7 h-7 flex items-center justify-center text-sm font-bold flex-shrink-0">2</div>
  398. <div class="text-sm">
  399. <div class="font-bold text-[#101419] mb-1">🍺 Elige tu cerveza favorita</div>
  400. <div class="text-[#58728d]">Selecciona cualquier cerveza hasta <span class="font-semibold">$5,000</span></div>
  401. </div>
  402. </div>
  403. <div class="flex items-start gap-3 p-3 bg-gray-50 rounded-lg border border-gray-200">
  404. <div class="bg-[#101419] text-white rounded-full w-7 h-7 flex items-center justify-center text-sm font-bold flex-shrink-0">3</div>
  405. <div class="text-sm">
  406. <div class="font-bold text-[#101419] mb-1">🎉 ¡Disfruta al máximo!</div>
  407. <div class="text-[#58728d]">Tu cerveza gratis está lista para disfrutar 🥳</div>
  408. </div>
  409. </div>
  410. </div>
  411. <!-- Nota importante -->
  412. <div class="bg-amber-50 border border-amber-200 rounded-lg p-3">
  413. <div class="flex items-center gap-2 mb-1">
  414. <span class="text-base">⏰</span>
  415. <h4 class="font-semibold text-amber-800 text-sm">Importante</h4>
  416. </div>
  417. <p class="text-amber-700 text-sm">Este premio es válido solo para el día de hoy. ¡No pierdas esta oportunidad!</p>
  418. </div>
  419. </div>
  420. <!-- Footer -->
  421. <div class="px-6 py-4 bg-gray-50 border-t border-gray-200">
  422. <button id="closeSuccessRewardModal" class="w-full bg-[#101419] hover:bg-[#37404a] text-white py-3 rounded-lg font-medium transition-colors duration-200">
  423. <span class="flex items-center justify-center gap-2">
  424. <span>🎊</span>
  425. Aceptar
  426. <span>🍻</span>
  427. </span>
  428. </button>
  429. </div>
  430. </div>
  431. </div>
  432. <div id="commentModal" class="hidden fixed inset-0 bg-black/70 flex items-center justify-center z-50 p-4">
  433. <div class="bg-white w-full max-w-md rounded-xl shadow-xl overflow-hidden">
  434. <div class="hidden bg-gray-50 px-6 py-4 border-b border-gray-200">
  435. <div class="flex items-center justify-between">
  436. <h2 id="titleComment" class="text-xl font-bold text-[#101419]">Titulo</h2>
  437. <button id="closeCommentModal" type="button" class="text-gray-400 hover:text-gray-600 text-2xl font-bold transition-colors">
  438. &times;
  439. </button>
  440. </div>
  441. </div>
  442. <!-- 2 posibles modals: un campo con textarea y boton de enviar o un campo desplegable con opciones -->
  443. <form id="selectCommentTypeForm" class="hidden">
  444. <div class="p-6 space-y-4">
  445. <p class="text-sm text-[#58728d]">
  446. Elige un sabor
  447. </p>
  448. <div id="selectOptions" class="flex flex-col gap-2">
  449. </div>
  450. </div>
  451. </form>
  452. <form id="commentForm" class="hidden">
  453. <div class="p-6 space-y-4">
  454. <p class="text-sm text-[#58728d]">
  455. ¿Alguna instrucción para la cocina? (Ej: sin cebolla, muy picante, alergias, etc.)
  456. </p>
  457. <div>
  458. <label for="commentTextarea" class="hidden text-sm font-medium text-gray-700 mb-2">
  459. Tu comentario
  460. </label>
  461. <textarea id="commentTextarea"
  462. name="comment"
  463. rows="4"
  464. class="w-full border border-gray-300 px-4 py-3 rounded-lg focus:ring-2 focus:ring-[#101419] focus:border-transparent outline-none transition-all"
  465. placeholder="Escribe tu comentario aquí..."></textarea>
  466. </div>
  467. </div>
  468. <div class="border-t border-gray-200 bg-gray-50 px-6 py-4 flex gap-3">
  469. <button id="cancelCommentBtn" type="button" class="flex-1 bg-gray-100 hover:bg-gray-200 text-gray-700 py-3 rounded-lg font-medium transition-colors duration-200">
  470. Cancelar
  471. </button>
  472. <button id="submitCommentBtn" type="submit" class="flex-1 bg-[#101419] hover:bg-[#37404a] text-white py-3 rounded-lg font-medium transition-colors duration-200">
  473. Guardar
  474. </button>
  475. </div>
  476. </form>
  477. </div>
  478. </div>
  479. <!-- ---------- JS: conmutar tabs + toast ---------- -->
  480. <script>
  481. // toast simple
  482. window.showToast = (msg) => {
  483. const toast = document.getElementById('toastCart');
  484. toast.textContent = msg;
  485. toast.style.animation = 'none'; // reset
  486. void toast.offsetWidth; // reflow
  487. toast.style.opacity = '1';
  488. toast.style.animation = 'popup 1s ease-out';
  489. toast.addEventListener('animationend', () => {
  490. toast.style.animation = 'none';
  491. toast.style.opacity = '0';
  492. });
  493. };
  494. </script>
  495. </body>
  496. </html>