Skip to content

Commit d88bb1f

Browse files
committed
- slight manual styling adjustments
- update timeline and add some fitting milestones - add background pattern from https://www.toptal.com/designers/subtlepatterns/crossword/
1 parent b2951a2 commit d88bb1f

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

img/crossword_pattern.png

35.6 KB
Loading

index.html

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
--shadow:0 2px 6px rgba(0,0,0,0.08); --radius:8px; --transition:all 0.2s ease;
2222
}
2323
* {margin:0; padding:0; box-sizing:border-box;}
24-
body {font-family:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; background:var(--bg); color:var(--text); line-height:1.5;}
24+
body {font-family:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; background:var(--bg); color:var(--text); line-height:1.5;background-image: url('img/crossword_pattern.png');}
2525
.container {width:100%; max-width:1280px; margin:0 auto; padding:0 1rem;}
2626
header {background:var(--card); box-shadow:var(--shadow); position:sticky; top:0; z-index:100;}
2727
.header-content {height:70px; display:flex; align-items:center; justify-content:space-between;}
@@ -49,7 +49,7 @@
4949
.view-all {color:var(--primary); text-decoration:none; font-weight:500;}
5050
.grid-view {display:grid; grid-template-columns:repeat(auto-fill, minmax(220px, 1fr)); gap:1.25rem; margin-bottom:3rem;}
5151
.list-view {display:flex; flex-direction:column; gap:1rem; margin-bottom:3rem;}
52-
.card {background:var(--card); border-radius:var(--radius); overflow:hidden; box-shadow:var(--shadow); transition:var(--transition); height:100%; display:flex; flex-direction:column; position:relative;}
52+
.card {cursor: pointer; background:var(--card); border-radius:var(--radius); overflow:hidden; box-shadow:var(--shadow); transition:var(--transition); height:100%; display:flex; flex-direction:column; position:relative;}
5353
.card:hover {box-shadow:0 8px 16px rgba(0,0,0,0.1); transform:translateY(-4px);}
5454
.card::before {content:''; position:absolute; bottom:0; left:0; width:100%; height:3px; background:var(--primary); transform:scaleX(0); transform-origin:left; transition:transform 0.3s ease; z-index:1;}
5555
.card:hover::before {transform:scaleX(1);}
@@ -68,7 +68,7 @@
6868
.card-title {font-size:1rem; font-weight:600; margin-bottom:0.5rem; color:var(--dark); display:-webkit-box; -webkit-line-clamp:1; -webkit-box-orient:vertical; overflow:hidden;}
6969
.card-desc {font-size:0.875rem; color:#495057; line-height:1.4; flex-grow:1;}
7070
.card-desc.truncated {overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical;}
71-
.read-more {color:var(--primary); background:none; border:none; font-size:0.8rem; cursor:pointer; padding:0; margin-bottom:1rem; align-self:flex-start; transition:var(--transition);}
71+
.read-more {color:var(--primary); background:none; border:none; font-size:0.8rem; cursor:pointer; padding:2rem; margin:-2rem -2rem -1rem -2rem; align-self:flex-start; transition:var(--transition);}
7272
.read-more:hover {color:var(--primary-hover); text-decoration:underline;}
7373
.card-btn {display:inline-block; padding:0.5rem 1rem; border-radius:var(--radius); text-decoration:none; font-weight:500; text-align:center; transition:var(--transition); margin-top:auto; border:none;}
7474
.card-btn.game {background:var(--primary); color:white;}
@@ -398,6 +398,16 @@ <h3 class="card-title" title="${item.title}">${item.title}</h3>
398398
this.textContent = descContainer.classList.contains('truncated') ? 'Read more' : 'Read less';
399399
});
400400
});
401+
402+
// make full card clickable
403+
document.querySelectorAll('.card').forEach(card => {
404+
card.addEventListener('click', e => {
405+
if (!e.target.closest('.read-more')) {
406+
console.log(e.currentTarget);
407+
card.querySelector('a').click();
408+
}
409+
});
410+
})
401411
}
402412

403413
// Sort items

0 commit comments

Comments
 (0)