Skip to content

Commit afbf4b3

Browse files
Add files via upload
1 parent 29dbf36 commit afbf4b3

1 file changed

Lines changed: 31 additions & 9 deletions

File tree

index.html

Lines changed: 31 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@
192192
}
193193
.overlay-card h2 { font-size: 1.8rem; color: #e94560; margin-bottom: 4px; }
194194
.overlay-card .subtitle { font-size: 0.95rem; color: #eee; font-weight: 600; margin-bottom: 2px; }
195-
.overlay-card .date { font-size: 0.82rem; color: #888; margin-bottom: 18px; }
195+
.overlay-card .date { font-size: 0.82rem; color: #888; margin-bottom: 0; }
196196
.overlay-card p { font-size: 0.97rem; color: #ccc; line-height: 1.5; margin-bottom: 24px; }
197197
.overlay-card button {
198198
padding: 12px 36px;
@@ -248,6 +248,23 @@
248248
text-transform: uppercase;
249249
letter-spacing: 0.06em;
250250
margin-bottom: 8px;
251+
cursor: pointer;
252+
user-select: none;
253+
display: flex;
254+
justify-content: space-between;
255+
align-items: center;
256+
}
257+
#score-panel .panel-title::after {
258+
content: '▲';
259+
font-size: 0.6rem;
260+
color: #555;
261+
transition: transform 0.2s;
262+
}
263+
#score-panel.collapsed .panel-title::after {
264+
transform: rotate(180deg);
265+
}
266+
#score-panel.collapsed #score-rows {
267+
display: none;
251268
}
252269
.score-row {
253270
display: flex;
@@ -322,14 +339,15 @@ <h1>GeoSpot</h1>
322339
<h2>GeoSpot</h2>
323340
<div class="subtitle" id="overlay-title"></div>
324341
<div class="date" id="overlay-date"></div>
325-
<svg viewBox="0 0 200 80" width="200" height="80" style="margin:16px auto 8px;display:block">
326-
<!-- dashed line -->
327-
<line x1="60" y1="50" x2="140" y2="30" stroke="white" stroke-width="1" stroke-dasharray="4 5" stroke-opacity="0.4"/>
328-
<!-- target dot (gold) -->
329-
<circle cx="140" cy="30" r="7" fill="#70a1ff" stroke="white" stroke-width="2"/>
330-
<!-- guess dot (red) with label -->
331-
<circle cx="60" cy="50" r="6" fill="#e94560" stroke="white" stroke-width="2"/>
332-
<text x="60" y="36" text-anchor="middle" fill="white" font-size="11" font-family="-apple-system,BlinkMacSystemFont,sans-serif" opacity="0.9">Bordeaux</text>
342+
<svg viewBox="0 0 200 80" width="200" height="80" style="margin:4px auto 8px;display:block">
343+
<!-- dashed line guess → target -->
344+
<line x1="68" y1="50" x2="132" y2="50" stroke="white" stroke-width="2" stroke-dasharray="4 7" stroke-linecap="round" stroke-opacity="0.75"/>
345+
<!-- guess dot (gold) -->
346+
<circle cx="68" cy="50" r="6" fill="#f5a623" stroke="#f9c87a" stroke-width="2"/>
347+
<!-- Bordeaux label above guess dot -->
348+
<text x="68" y="37" text-anchor="middle" fill="#f5a623" font-size="11" font-weight="700" font-family="-apple-system,BlinkMacSystemFont,sans-serif">Bordeaux</text>
349+
<!-- target dot (blue) -->
350+
<circle cx="132" cy="50" r="6" fill="#70a1ff" stroke="#a8c8ff" stroke-width="2"/>
333351
</svg>
334352
<p>Trouve la ville la plus proche possible de la cible.</p>
335353
<button id="play-btn">Jouer</button>
@@ -822,6 +840,10 @@ <h2>GeoSpot</h2>
822840
}
823841

824842
// ── Share ─────────────────────────────────────────────────────────────────
843+
document.querySelector('#score-panel .panel-title').addEventListener('click', () => {
844+
document.getElementById('score-panel').classList.toggle('collapsed');
845+
});
846+
825847
document.getElementById('share-btn').addEventListener('click', () => {
826848
const total = guesses.reduce((s, g) => s + g.dist, 0);
827849
function distEmoji(dist) {

0 commit comments

Comments
 (0)