Mobile First Overhaul: Touch gestures, dual tap/drag, instant responsiveness and ergonomic controls across all mini games

This commit is contained in:
Maxi
2026-09-22 19:57:56 +02:00
parent 2ce944d1cd
commit 5551c4e54f
13 changed files with 443 additions and 319 deletions
+36 -32
View File
@@ -5,10 +5,9 @@
{% block content %}
<div class="parchment-scroll">
<h1 class="parchment-title">⚗️ Kammer III: Die Zaubertrank-Brauküche ⚗️</h1>
<p class="riddle-poem" style="font-size: 1.25rem;">
"Dichte Dämpfe steigen aus dem massiven Kupferkessel auf.<br>
Um das nächste Kerkertor aufzuschmelzen, musst du einen legendären Trank vollenden:<br>
<strong>Felix Felicis – Das flüssige Gold des Glücks!</strong>"
<p class="riddle-poem" style="font-size: 1.15rem; margin: 0.3rem 0;">
"Snapes Kupferkessel dampft im Halbdunkel des Kerkers.<br>
Braue das flüssige Gold des Glücks: <strong>Felix Felicis</strong>!"
</p>
</div>
@@ -16,11 +15,11 @@
<!-- Recipe Instruction Scroll -->
<div class="recipe-book">
<span id="stepBadge" class="recipe-step-badge">Schritt 1: Zutaten zugeben</span>
<h3 id="stepInstruction" style="color: var(--gold); margin: 0.25rem 0; font-size: 1.35rem;">
<h3 id="stepInstruction" style="color: var(--gold); margin: 0.25rem 0; font-size: 1.25rem;">
Gib die 4 Essenzen in den Kessel!
</h3>
<p id="stepSubtext" style="color: var(--text-dim); font-size: 0.95rem; margin: 0;">
Tippe auf die Zutaten im Regal, um sie in den brodelnden Sud zu geben.
<p id="stepSubtext" style="color: var(--text-dim); font-size: 0.9rem; margin: 0;">
Tippe auf die Zutaten unten, um sie in den Kessel zu werfen.
</p>
</div>
@@ -28,8 +27,7 @@
<div class="cauldron-wrapper" id="cauldronZone">
<!-- Interactive Stir Ring Overlay -->
<div id="stirCircle" class="stir-circle">
<span class="stir-arrow-hint">↻</span>
<div id="stirTracker" style="width: 20px; height: 20px; background: var(--gold); border-radius: 50%; box-shadow: 0 0 10px #fff;"></div>
<span class="stir-arrow-hint">🥄</span>
</div>
<div class="cauldron-pot">
@@ -38,11 +36,6 @@
<div class="cauldron-fire">🔥</div>
</div>
<!-- Stir Status Hint -->
<div id="stirCounterText" style="display: none; color: var(--gold); font-size: 1.2rem; font-weight: bold;">
Rühre im Uhrzeigersinn: <span id="stirCount">0</span> / 3 Runden
</div>
<!-- Step 1: Ingredient Shelf -->
<div id="ingredientsShelf" class="ingredients-shelf">
<button type="button" class="ingredient-btn" id="ingDragon" onclick="addIngredient('dragon')">
@@ -62,44 +55,55 @@
</button>
</div>
<!-- Step 2: Stir Control Panel (Mobile Friendly!) -->
<div id="stirPanel" style="display: none; flex-direction: column; align-items: center; gap: 0.5rem; width: 100%;">
<button type="button" id="stirBtn" class="btn-magical" style="padding: 0.9rem 1.8rem; font-size: 1.15rem; width: 100%; max-width: 320px;" onclick="doStir()">
🥄 Kessel umrühren! (<span id="stirCount">0</span> / 3)
</button>
<span style="color: var(--text-dim); font-size: 0.85rem;">Tippe auf den Button oder wische über den Kessel</span>
</div>
<!-- Step 3: Heat Control Panel -->
<div id="heatPanel" class="heat-control-panel">
<div style="color: var(--text-light); font-size: 0.95rem;">
🌡️ Halte die Kesseltemperatur für <strong>4 Sekunden</strong> im grünen Bereich:
<div style="color: var(--text-light); font-size: 0.95rem; text-align: center;">
🌡️ Halte die Temperatur mit dem Blasebalg im grünen Bereich:
</div>
<div class="temp-bar-container">
<div class="temp-ideal-zone"></div>
<div id="tempIndicator" class="temp-indicator"></div>
</div>
<div style="display: flex; justify-content: space-between; width: 100%; max-width: 320px; font-size: 0.8rem; color: var(--text-dim);">
<span>Kalt (0°C)</span>
<span style="color: #2ecc71; font-weight: bold;">Ideal (70-90°C)</span>
<span>Überhitzt (120°C)</span>
<span>Kalt</span>
<span style="color: #2ecc71; font-weight: bold;">Ideal (50% - 85%)</span>
<span>Zu heiß!</span>
</div>
<div style="color: var(--gold); font-weight: bold; margin-top: 0.25rem;">
Ideale Hitze gehalten: <span id="heatTimer">0.0</span> / 4.0s
Ideale Hitze gehalten: <span id="heatTimer">0.0</span> / 3.0s
</div>
<button type="button" id="bellowsBtn" class="bellows-btn" onclick="pumpHeat()">
🔥 Blasebalg drücken!
🔥 Blasebalg pumpen!
</button>
</div>
<!-- Success Container -->
<div id="successPanel" style="display: none; text-align: center; margin-top: 1rem;">
<h2 style="color: var(--gold); font-size: 1.8rem; margin-bottom: 0.5rem;">
✨ Felix Felicis vollendet! ✨
</h2>
<p style="color: var(--text-light); max-width: 500px; margin: 0 auto 1.25rem auto;">
Der Kessel erstrahlt in goldenem Sonnenlicht! Eine Phiole des reinen flüssigen Glücks fließt magisch in deinen Zauberbeutel.
</p>
<div style="display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;">
<a href="/cryptex" class="btn-magical">Zur nächsten Kammer: Das Drehschloss 🔐➔</a>
<a href="/" class="btn-control">Zurück zur Übersicht 🏰</a>
<div id="successPanel" style="display: none; text-align: center; margin-top: 1rem; width: 100%;">
<div class="dungeon-card" style="border-color: #2ecc71;">
<div style="font-size: 3rem; margin-bottom: 0.5rem;">🧪✨🍀</div>
<h2 style="color: var(--gold); font-size: 1.8rem; margin-bottom: 0.5rem;">
Felix Felicis vollendet!
</h2>
<p style="color: var(--text-light); max-width: 500px; margin: 0 auto 1.25rem auto;">
Der Kessel erstrahlt in gleißendem Gold! Eine Phiole des reinen flüssigen Glücks wandert in deinen <strong>Zauberbeutel</strong>.
</p>
<div style="display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;">
<a href="/cryptex" class="btn-magical">Zur nächsten Kammer: Das Drehschloss 🔐➔</a>
<a href="/" class="btn-control">Zurück zur Übersicht 🏰</a>
</div>
</div>
</div>
</div>
{% endblock %}
{% block scripts %}
<script src="/static/js/brew.js?v=1.0"></script>
<script src="/static/js/brew.js?v=2.0"></script>
{% endblock %}