diff --git a/app.py b/app.py index 6dcef34..5b5ec9c 100644 --- a/app.py +++ b/app.py @@ -1753,13 +1753,29 @@ def public_frontend(): time_block = "" if time_html: time_overlay = f'
{time_html}
' - if media_first: - time_block = time_overlay - else: - time_block = f'
{time_html}
' + time_block = time_overlay # Always overlay now elif not media_first: - time_block = f'
{date_str}
' - cards += f"""
+ time_block = '' + + if not media_first: + # Text-only card: link-wrapped, time overlay inside card-content + cards += f""" +
+ """ + (f'
📍 {r["halle"]}
' if r["halle"] else '') + """ + """ + (f'
🚫 AUSVERKAUFT: {r["spiel_titel"]}
' if r["category"] == "ausverkauft" and r["spiel_titel"] else '') + """ +
+ """ + time_block + """ + +

""" + preview + """

+
+
+
""" + else: + # Media card: existing structure + cards += f"""
""" + media_first + time_block + """ """ + (f'
📍 {r["halle"]}
' if r["halle"] else '') + """ """ + (f'
🚫 AUSVERKAUFT: {r["spiel_titel"]}
' if r["category"] == "ausverkauft" and r["spiel_titel"] else '') + """ @@ -1797,9 +1813,14 @@ def public_frontend(): /* Main grid — masonry (CSS columns) */ .main-grid { max-width:1300px; margin:1.5rem auto; padding:0 1rem; column-count:4; column-gap:1.2rem; } + /* Card link wrapper (text-only) */ + .card-link { text-decoration:none; color:inherit; display:inline-block; width:100%; margin-bottom:1.2rem; break-inside:avoid; } + .card-link:hover .story-card { transform:translateY(-3px); box-shadow:0 8px 32px rgba(0,0,0,0.18),0 3px 10px rgba(0,0,0,0.08); } + /* Card — masonry tiles, compact */ .story-card { background:#fff; border-radius:14px; overflow:hidden; box-shadow:0 4px 18px rgba(0,0,0,0.10),0 1px 4px rgba(0,0,0,0.05); transition:box-shadow 0.25s ease,transform 0.2s ease; display:inline-block; width:100%; margin-bottom:1.2rem; break-inside:avoid; } .story-card:hover { transform:translateY(-3px); box-shadow:0 8px 32px rgba(0,0,0,0.18),0 3px 10px rgba(0,0,0,0.08); } + a.card-link .story-card { margin-bottom:0; } .story-card img { width:100%; height:100%; object-fit:cover; display:block; } .story-card video { width:100%; height:auto; max-height:600px; object-fit:contain; display:block; background:#000; } .story-card { position:relative; } @@ -1816,7 +1837,8 @@ def public_frontend(): .story-time-overlay .story-time-rel { color:#dc3545; } .story-preview { display:none; } .text-only .story-preview { display:-webkit-box; -webkit-line-clamp:4; -webkit-box-orient:vertical; overflow:hidden; text-overflow:ellipsis; font-size:0.8rem; line-height:1.4; color:#444; margin-bottom:0.35rem; } - .text-only .card-content { padding:0.55rem 0.85rem 0.65rem; } + .text-only .card-content { position:relative; padding:0.55rem 0.85rem 0.65rem; } + .text-only .story-time-overlay { position:absolute; top:0.45rem; right:0.6rem; left:auto; z-index:5; } /* Frontend filter bar */ .frontend-filter { max-width:1100px; margin:1rem auto 0; padding:0 1.5rem; display:flex; gap:0.4rem; flex-wrap:wrap; align-items:center; }