jekyll-theme-zer0 0.5.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/_layouts/blog.html CHANGED
@@ -4,275 +4,467 @@ source: "https://getbootstrap.com/docs/5.3/examples/blog/#"
4
4
  ---
5
5
  <!--
6
6
  ===================================================================
7
- BLOG LAYOUT - Modern blog homepage with featured content
7
+ BLOG LAYOUT - Full-Width News Homepage
8
8
  ===================================================================
9
9
 
10
10
  File: blog.html
11
11
  Path: _layouts/blog.html
12
12
  Inherits: root.html
13
- Purpose: Full-featured blog homepage with content organization
13
+ Purpose: Main news homepage with full-width content sections
14
14
  Source: Adapted from Bootstrap 5.3 blog example
15
15
 
16
- Template Logic:
17
- - Creates a magazine-style blog layout with multiple content sections
18
- - Features breaking news/highlighted posts prominently
19
- - Displays featured posts in a card grid layout
20
- - Includes sidebar with recent posts, archives, and categories
21
- - Implements responsive design for mobile and desktop
22
- - Provides navigation between posts with pagination
16
+ Layout Structure (NO SIDEBAR - Full Width):
17
+ 1. Blog Header: Dark header with title and category navigation
18
+ 2. Hero Section: Breaking news highlight with large image
19
+ 3. Category Navigation: Quick links to all sections with article counts
20
+ 4. Featured Stories: Top featured posts in card grid
21
+ 5. Category Sections: Posts organized by top 3 categories
22
+ 6. Latest Posts: Horizontal card list of recent posts
23
+ 7. Tags & Archives: Discovery widgets
24
+ 8. Newsletter: Subscription CTA
23
25
 
24
- Layout Structure:
25
- 1. Blog Header: Subscribe, logo/title, search, and sign-up
26
- 2. Navigation Bar: Dynamic navigation from site data
27
- 3. Hero Section: Most recent breaking news post
28
- 4. Featured Posts: Grid of featured content
29
- 5. Main Content: Blog content with pagination
30
- 6. Sidebar: Recent posts, archives, categories, external links
31
-
32
- Content Logic:
33
- - Breaking news: Posts with "breaking" category
34
- - Featured posts: Posts with "featured: true" in frontmatter
35
- - Recent posts: Latest 3 posts for sidebar
36
- - Navigation: Dynamic from site.data.navigation.posts
37
-
38
- Responsive Features:
39
- - Mobile-first responsive grid system
40
- - Image optimization with responsive classes
41
- - Collapsible navigation and mobile-friendly layout
26
+ Note: All cards are inlined to avoid Liquid nesting depth issues
42
27
  ===================================================================
43
28
  -->
44
29
 
45
30
  <!-- ================================ -->
46
- <!-- BLOG HEADER SECTION -->
31
+ <!-- BLOG HEADER -->
47
32
  <!-- ================================ -->
48
- <div class="container">
49
- <header class="border-bottom lh-1 py-3">
50
- <div class="row flex-nowrap justify-content-between align-items-center">
51
- <!-- Subscription Link -->
52
- <div class="col-4 pt-1">
53
- <a class="link-secondary" href="#">Subscribe</a>
54
- </div>
55
-
56
- <!-- Blog Title/Logo -->
57
- <div class="col-4 text-center">
58
- <a class="blog-header-logo text-body-emphasis text-decoration-none" href="#">
59
- {{ page.title }}
60
- </a>
61
- </div>
62
-
63
- <!-- Search and Sign-up -->
64
- <div class="col-4 d-flex justify-content-end align-items-center">
65
- <!-- Search Icon -->
66
- <a class="link-secondary" href="#" aria-label="Search">
67
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" class="mx-3" role="img" viewBox="0 0 24 24">
68
- <title>Search</title>
69
- <circle cx="10.5" cy="10.5" r="7.5"/>
70
- <path d="M21 21l-5.2-5.2"/>
71
- </svg>
72
- </a>
73
- <a class="btn btn-sm btn-outline-secondary" href="#">Sign up</a>
74
- </div>
75
- </div>
76
- </header>
77
-
78
- <!-- ================================ -->
79
- <!-- NAVIGATION BAR -->
80
- <!-- ================================ -->
81
- <!-- Dynamic navigation from site data configuration -->
82
- <div class="nav-scroller py-1 mb-3 border-bottom">
83
- <nav class="nav nav-underline justify-content-between">
84
- {% for item in site.data.navigation.posts %}
85
- <a class="nav-item nav-link link-body-emphasis" href="{{ item.url | relative_url }}">
86
- {{ item.title }}
87
- </a>
88
- {% endfor %}
33
+ <div class="container-fluid bg-dark text-white py-3 mb-4">
34
+ <div class="container">
35
+ <div class="row align-items-center">
36
+ <div class="col-md-4">
37
+ <h1 class="h3 mb-0">
38
+ <i class="bi bi-newspaper me-2"></i>{{ page.title | default: "News" }}
39
+ </h1>
40
+ </div>
41
+ <div class="col-md-8">
42
+ <nav class="nav nav-pills justify-content-md-end flex-wrap">
43
+ <a class="nav-link text-white active" href="{{ site.baseurl }}/posts/">
44
+ <i class="bi bi-house me-1"></i>Home
45
+ </a>
46
+ {% for item in site.data.navigation.posts %}
47
+ <a class="nav-link text-white-50" href="{{ item.url | relative_url }}">
48
+ {% if item.icon %}<i class="bi bi-{{ item.icon }} me-1"></i>{% endif %}
49
+ {{ item.title }}
50
+ </a>
51
+ {% endfor %}
52
+ <a class="nav-link text-white-50" href="{{ site.baseurl }}/tags/">
53
+ <i class="bi bi-tags me-1"></i>Tags
54
+ </a>
89
55
  </nav>
56
+ </div>
90
57
  </div>
58
+ </div>
91
59
  </div>
92
60
 
93
- <!-- ================================ -->
94
- <!-- MAIN CONTENT CONTAINER -->
95
- <!-- ================================ -->
96
61
  <main class="container">
97
-
98
- <!-- ================================ -->
99
- <!-- HERO SECTION - Breaking News -->
100
- <!-- ================================ -->
101
- <!-- Featured highlight of most recent breaking news post -->
102
- {% assign breaking_news_posts = site.posts | where: "categories", "breaking" %}
103
- {% assign most_recent_post = breaking_news_posts | first %}
104
62
 
105
- <div class="p-4 p-md-5 mb-4 rounded text-body-emphasis bg-body-secondary">
106
- <div class="row">
107
- <!-- Breaking News Content -->
108
- <div class="col-lg-6">
109
- <h1 class="display-4 fst-italic">{{ most_recent_post.title }}</h1>
110
- <p class="lead my-3">{{ most_recent_post.excerpt }}</p>
111
- <p class="lead mb-0">
112
- <a href="{{ site.baseurl }}{{ most_recent_post.url }}" class="text-body-emphasis fw-bold">
113
- Continue reading...
114
- </a>
115
- </p>
116
- </div>
117
-
118
- <!-- Breaking News Image -->
119
- <div class="col-lg-6">
120
- <img src="{{ site.baseurl }}/{{ site.public_folder }}/{{ most_recent_post.preview }}"
121
- alt="Preview image" class="img-fluid">
122
- </div>
63
+ <!-- ================================ -->
64
+ <!-- HERO - BREAKING NEWS -->
65
+ <!-- ================================ -->
66
+ {% assign breaking_posts = site.posts | where: "breaking", true | where_exp: "post", "post.layout != 'blog'" %}
67
+ {% assign hero_post = breaking_posts | first %}
68
+
69
+ {% unless hero_post %}
70
+ {% assign hero_post = site.posts | where: "featured", true | where_exp: "post", "post.layout != 'blog'" | first %}
71
+ {% endunless %}
72
+
73
+ {% if hero_post %}
74
+ <section class="hero-section mb-5">
75
+ <div class="row g-0 bg-body-secondary rounded-4 overflow-hidden shadow">
76
+ <div class="col-lg-6 p-4 p-lg-5 d-flex flex-column justify-content-center">
77
+ {% if hero_post.breaking %}
78
+ <span class="badge bg-danger mb-3 align-self-start">
79
+ <i class="bi bi-lightning-fill me-1"></i>Breaking News
80
+ </span>
81
+ {% elsif hero_post.featured %}
82
+ <span class="badge bg-warning text-dark mb-3 align-self-start">
83
+ <i class="bi bi-star-fill me-1"></i>Featured
84
+ </span>
85
+ {% endif %}
86
+ <h1 class="display-5 fw-bold mb-3">{{ hero_post.title }}</h1>
87
+ <p class="lead text-muted mb-4">{{ hero_post.excerpt | strip_html | truncate: 200 }}</p>
88
+ <div class="d-flex align-items-center gap-3 mb-4 flex-wrap">
89
+ <small class="text-muted">
90
+ <i class="bi bi-calendar me-1"></i>{{ hero_post.date | date: "%B %d, %Y" }}
91
+ </small>
92
+ {% if hero_post.author %}
93
+ <small class="text-muted">
94
+ <i class="bi bi-person me-1"></i>{{ hero_post.author }}
95
+ </small>
96
+ {% endif %}
97
+ {% if hero_post.categories.size > 0 %}
98
+ <a href="{{ site.baseurl }}/posts/{{ hero_post.categories | first | slugify }}/" class="badge bg-primary text-decoration-none">
99
+ {{ hero_post.categories | first }}
100
+ </a>
101
+ {% endif %}
123
102
  </div>
103
+ <a href="{{ hero_post.url | relative_url }}" class="btn btn-primary btn-lg align-self-start">
104
+ Read Full Story <i class="bi bi-arrow-right ms-2"></i>
105
+ </a>
106
+ </div>
107
+ <div class="col-lg-6">
108
+ {% if hero_post.preview %}
109
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ hero_post.preview }}"
110
+ class="w-100 h-100" style="object-fit: cover; min-height: 400px;"
111
+ alt="{{ hero_post.title }}" loading="lazy">
112
+ {% else %}
113
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ site.og_image }}"
114
+ class="w-100 h-100" style="object-fit: cover; min-height: 400px;"
115
+ alt="Featured image" loading="lazy">
116
+ {% endif %}
117
+ </div>
124
118
  </div>
119
+ </section>
120
+ {% endif %}
125
121
 
126
- <!-- ================================ -->
127
- <!-- FEATURED POSTS GRID -->
128
- <!-- ================================ -->
129
- <!-- Two-column grid of featured posts marked with 'featured: true' -->
130
- <div class="row mb-2">
131
- {% assign featured_posts = site.posts | where: "featured", true %}
132
- {% for post in featured_posts %}
133
- <div class="col-md-6">
134
- <div class="row g-0 border rounded overflow-hidden flex-md-row mb-4 shadow-sm h-md-250 position-relative">
135
- <!-- Post Content -->
136
- <div class="col p-4 d-flex flex-column position-static">
137
- <strong class="d-inline-block mb-2 text-primary-emphasis">
138
- {{ post.categories[0] }}
139
- </strong>
140
- <h3 class="mb-0">{{ post.title }}</h3>
141
- <div class="mb-1 text-body-secondary">{{ post.date | date: "%b %d" }}</div>
142
- <p class="card-text mb-auto">{{ post.excerpt | strip_html | truncate: 200 }}</p>
143
- <a href="{{ site.baseurl }}{{ post.url }}" class="icon-link gap-1 icon-link-hover stretched-link">
144
- Continue reading
145
- <svg class="bi"><use xlink:href="#chevron-right"/></svg>
146
- </a>
147
- </div>
148
-
149
- <!-- Post Preview Image -->
150
- <div class="col-md-6 d-none d-lg-block">
151
- <img src="{{ site.baseurl }}/{{ site.public_folder }}/{{ post.preview }}"
152
- alt="Post preview image" class="img-fluid">
153
- </div>
154
- </div>
122
+ <!-- ================================ -->
123
+ <!-- CATEGORY QUICK NAVIGATION -->
124
+ <!-- ================================ -->
125
+ <section class="category-nav mb-5">
126
+ <div class="row row-cols-2 row-cols-md-3 row-cols-lg-6 g-3">
127
+ {% for nav_item in site.data.navigation.posts %}
128
+ {% assign cat_posts = site.posts | where_exp: "post", "post.categories contains nav_item.title" %}
129
+ <div class="col">
130
+ <a href="{{ nav_item.url | relative_url }}"
131
+ class="card text-center h-100 text-decoration-none border-0 shadow-sm hover-lift">
132
+ <div class="card-body py-4">
133
+ <i class="bi bi-{{ nav_item.icon | default: 'folder' }} fs-2 text-primary mb-2 d-block"></i>
134
+ <h6 class="card-title mb-1">{{ nav_item.title }}</h6>
135
+ <small class="text-muted">{{ cat_posts.size }} articles</small>
155
136
  </div>
156
- {% endfor %}
137
+ </a>
138
+ </div>
139
+ {% endfor %}
157
140
  </div>
141
+ </section>
158
142
 
159
- <!-- ================================ -->
160
- <!-- MAIN CONTENT AND SIDEBAR -->
161
- <!-- ================================ -->
162
- <div class="row g-5">
163
- <!-- ========================== -->
164
- <!-- MAIN CONTENT COLUMN -->
165
- <!-- ========================== -->
166
- <div class="col-md-8">
167
- <h3 class="pb-4 mb-4 fst-italic border-bottom">From the Firehose</h3>
168
-
169
- <!-- Blog Post Content -->
170
- <article class="blog-post">
171
- {{ content }}
172
- </article>
173
-
174
- <!-- ========================== -->
175
- <!-- POST PAGINATION -->
176
- <!-- ========================== -->
177
- <!-- Previous and Next page navigation -->
178
- <nav aria-label="Page navigation">
179
- <ul class="pagination pagination-lg justify-content-center">
180
- <li class="page-item">
181
- {% if page.previous %}
182
- <a class="page-link" href="{{ page.previous.url | prepend: site.baseurl }}">
183
- Previous: {{ page.previous.title }}
184
- </a>
185
- {% else %}
186
- <a class="page-link" href="#" aria-disabled="true">Previous</a>
187
- {% endif %}
188
- </li>
189
- <li class="page-item">
190
- {% if page.next %}
191
- <a class="page-link" href="{{ page.next.url | prepend: site.baseurl }}">
192
- Next: {{ page.next.title }}
193
- </a>
194
- {% else %}
195
- <a class="page-link" href="#" aria-disabled="true">Next</a>
196
- {% endif %}
197
- </li>
198
- </ul>
199
- </nav>
143
+ <!-- ================================ -->
144
+ <!-- FEATURED STORIES -->
145
+ <!-- ================================ -->
146
+ {% assign featured_posts = site.posts | where: "featured", true | where_exp: "post", "post.layout != 'blog'" %}
147
+ {% if featured_posts.size > 0 %}
148
+ <section class="featured-section mb-5">
149
+ <div class="d-flex justify-content-between align-items-center mb-4">
150
+ <h2 class="h3 mb-0">
151
+ <i class="bi bi-star-fill text-warning me-2"></i>Featured Stories
152
+ </h2>
153
+ </div>
154
+
155
+ <div class="row g-4">
156
+ <!-- Main Featured Post -->
157
+ {% assign main_featured = featured_posts | first %}
158
+ <div class="col-lg-6">
159
+ <div class="card h-100 border-0 shadow">
160
+ <div class="position-relative">
161
+ <span class="badge bg-warning text-dark position-absolute top-0 end-0 m-3 z-1">
162
+ <i class="bi bi-star-fill me-1"></i>Featured
163
+ </span>
164
+ <a href="{{ main_featured.url | relative_url }}">
165
+ {% if main_featured.preview %}
166
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ main_featured.preview }}"
167
+ class="card-img-top" style="height: 300px; object-fit: cover;"
168
+ alt="{{ main_featured.title }}" loading="lazy">
169
+ {% else %}
170
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ site.teaser }}"
171
+ class="card-img-top" style="height: 300px; object-fit: cover;"
172
+ alt="Preview" loading="lazy">
173
+ {% endif %}
174
+ </a>
175
+ </div>
176
+ <div class="card-body">
177
+ {% if main_featured.categories.size > 0 %}
178
+ <a href="{{ site.baseurl }}/posts/{{ main_featured.categories | first | slugify }}/"
179
+ class="badge bg-primary text-decoration-none mb-2">
180
+ {{ main_featured.categories | first }}
181
+ </a>
182
+ {% endif %}
183
+ <h4 class="card-title">
184
+ <a href="{{ main_featured.url | relative_url }}" class="text-decoration-none text-body-emphasis">
185
+ {{ main_featured.title }}
186
+ </a>
187
+ </h4>
188
+ <p class="card-text text-muted">{{ main_featured.excerpt | strip_html | truncate: 150 }}</p>
189
+ </div>
190
+ <div class="card-footer bg-transparent">
191
+ <small class="text-muted">
192
+ <i class="bi bi-calendar me-1"></i>{{ main_featured.date | date: "%b %d, %Y" }}
193
+ {% if main_featured.author %}
194
+ <span class="mx-2">•</span>
195
+ <i class="bi bi-person me-1"></i>{{ main_featured.author }}
196
+ {% endif %}
197
+ </small>
198
+ </div>
200
199
  </div>
201
-
202
- <!-- ========================== -->
203
- <!-- SIDEBAR COLUMN -->
204
- <!-- ========================== -->
205
- <div class="col-md-4">
206
- <div class="position-sticky" style="top: 2rem;">
207
-
208
- <!-- About Section -->
209
- <div class="p-4 mb-3 bg-body-tertiary rounded">
210
- <h4 class="fst-italic">About</h4>
211
- <p class="mb-0">
212
- Customize this section to tell your visitors a little bit about your publication,
213
- writers, content, or something else entirely. Totally up to you.
214
- </p>
200
+ </div>
201
+
202
+ <!-- Secondary Featured Posts -->
203
+ <div class="col-lg-6">
204
+ <div class="row row-cols-1 row-cols-md-2 g-4">
205
+ {% for fpost in featured_posts offset:1 limit:4 %}
206
+ <div class="col">
207
+ <div class="card h-100 border-0 shadow-sm hover-lift">
208
+ <a href="{{ fpost.url | relative_url }}">
209
+ {% if fpost.preview %}
210
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ fpost.preview }}"
211
+ class="card-img-top" style="height: 120px; object-fit: cover;"
212
+ alt="{{ fpost.title }}" loading="lazy">
213
+ {% else %}
214
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ site.teaser }}"
215
+ class="card-img-top" style="height: 120px; object-fit: cover;"
216
+ alt="Preview" loading="lazy">
217
+ {% endif %}
218
+ </a>
219
+ <div class="card-body py-3">
220
+ <h6 class="card-title mb-1">
221
+ <a href="{{ fpost.url | relative_url }}" class="text-decoration-none text-body-emphasis">
222
+ {{ fpost.title | truncate: 50 }}
223
+ </a>
224
+ </h6>
225
+ <small class="text-muted">{{ fpost.date | date: "%b %d" }}</small>
215
226
  </div>
227
+ </div>
228
+ </div>
229
+ {% endfor %}
230
+ </div>
231
+ </div>
232
+ </div>
233
+ </section>
234
+ {% endif %}
216
235
 
217
- <!-- Recent Posts Section -->
218
- <div>
219
- <h4 class="fst-italic">Recent posts</h4>
220
- <ul class="list-unstyled">
221
- {% for post in site.posts limit:3 %}
222
- <li>
223
- <a class="d-flex flex-column flex-lg-row gap-3 align-items-start align-items-lg-center py-3 link-body-emphasis text-decoration-none border-top"
224
- href="{{site.baseurl}}/{{ post.url }}">
225
- <img class="bd-placeholder-img"
226
- src="{{ site.baseurl }}/{{ site.public_folder }}/{{ page.preview | default: site.og_image }}"
227
- width="50%" alt="Preview image">
228
- <div class="col-lg-8">
229
- <h6 class="mb-0">{{ post.title }}</h6>
230
- <small class="text-body-secondary">{{ post.date | date: "%B %d, %Y" }}</small>
231
- </div>
232
- </a>
233
- </li>
234
- {% endfor %}
235
- </ul>
236
- </div>
236
+ <!-- ================================ -->
237
+ <!-- POSTS BY CATEGORY -->
238
+ <!-- ================================ -->
239
+ {% for nav_item in site.data.navigation.posts limit: 3 %}
240
+ {% assign cat_posts = site.posts | where_exp: "post", "post.categories contains nav_item.title" | where_exp: "post", "post.layout != 'blog'" %}
241
+ {% if cat_posts.size > 0 %}
242
+ <section class="category-section mb-5 pb-4 border-bottom">
243
+ <div class="d-flex justify-content-between align-items-center mb-4">
244
+ <h2 class="h4 mb-0">
245
+ <i class="bi bi-{{ nav_item.icon | default: 'folder' }} text-primary me-2"></i>{{ nav_item.title }}
246
+ </h2>
247
+ <a href="{{ nav_item.url | relative_url }}" class="btn btn-outline-secondary btn-sm">
248
+ View All {{ nav_item.title }} <i class="bi bi-arrow-right ms-1"></i>
249
+ </a>
250
+ </div>
251
+
252
+ <div class="row g-4">
253
+ {% for cpost in cat_posts limit: 4 %}
254
+ <div class="col-md-6 col-lg-3">
255
+ <div class="card h-100 border-0 shadow-sm hover-lift">
256
+ <a href="{{ cpost.url | relative_url }}">
257
+ {% if cpost.preview %}
258
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ cpost.preview }}"
259
+ class="card-img-top" style="height: 140px; object-fit: cover;"
260
+ alt="{{ cpost.title }}" loading="lazy">
261
+ {% else %}
262
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ site.teaser }}"
263
+ class="card-img-top" style="height: 140px; object-fit: cover;"
264
+ alt="Preview" loading="lazy">
265
+ {% endif %}
266
+ </a>
267
+ <div class="card-body">
268
+ <h6 class="card-title">
269
+ <a href="{{ cpost.url | relative_url }}" class="text-decoration-none text-body-emphasis">
270
+ {{ cpost.title | truncate: 55 }}
271
+ </a>
272
+ </h6>
273
+ <p class="card-text small text-muted mb-0">
274
+ {{ cpost.excerpt | strip_html | truncate: 80 }}
275
+ </p>
276
+ </div>
277
+ <div class="card-footer bg-transparent border-0 pt-0">
278
+ <small class="text-muted">
279
+ <i class="bi bi-calendar me-1"></i>{{ cpost.date | date: "%b %d, %Y" }}
280
+ </small>
281
+ </div>
282
+ </div>
283
+ </div>
284
+ {% endfor %}
285
+ </div>
286
+ </section>
287
+ {% endif %}
288
+ {% endfor %}
237
289
 
238
- <!-- Archives Section -->
239
- <!-- Note: This section uses static links - consider making dynamic -->
240
- <div class="p-4">
241
- <h4 class="fst-italic">Archives</h4>
242
- <ol class="list-unstyled mb-0">
243
- <li><a href="#">March 2021</a></li>
244
- <li><a href="#">February 2021</a></li>
245
- <li><a href="#">January 2021</a></li>
246
- <li><a href="#">December 2020</a></li>
247
- <li><a href="#">November 2020</a></li>
248
- <li><a href="#">October 2020</a></li>
249
- <li><a href="#">September 2020</a></li>
250
- <li><a href="#">August 2020</a></li>
251
- <li><a href="#">July 2020</a></li>
252
- <li><a href="#">June 2020</a></li>
253
- <li><a href="#">May 2020</a></li>
254
- <li><a href="#">April 2020</a></li>
255
- </ol>
290
+ <!-- ================================ -->
291
+ <!-- LATEST POSTS -->
292
+ <!-- ================================ -->
293
+ {% assign latest_posts = site.posts | where_exp: "post", "post.layout != 'blog'" %}
294
+ <section class="latest-section mb-5">
295
+ <div class="d-flex justify-content-between align-items-center mb-4">
296
+ <h2 class="h4 mb-0">
297
+ <i class="bi bi-clock-history text-secondary me-2"></i>Latest Posts
298
+ </h2>
299
+ </div>
300
+
301
+ <div class="row g-4">
302
+ {% for lpost in latest_posts limit: 6 %}
303
+ <div class="col-md-6 col-lg-4">
304
+ <div class="card border-0 shadow-sm h-100 hover-lift">
305
+ <div class="row g-0">
306
+ <div class="col-4">
307
+ <a href="{{ lpost.url | relative_url }}">
308
+ {% if lpost.preview %}
309
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ lpost.preview }}"
310
+ class="rounded-start h-100 w-100" style="object-fit: cover; min-height: 120px;"
311
+ alt="{{ lpost.title }}" loading="lazy">
312
+ {% else %}
313
+ <img src="{{ site.baseurl }}/{{ site.public_folder }}{{ site.teaser }}"
314
+ class="rounded-start h-100 w-100" style="object-fit: cover; min-height: 120px;"
315
+ alt="Preview" loading="lazy">
316
+ {% endif %}
317
+ </a>
318
+ </div>
319
+ <div class="col-8">
320
+ <div class="card-body py-2 px-3">
321
+ {% if lpost.categories.size > 0 %}
322
+ <span class="badge bg-secondary mb-1">{{ lpost.categories | first }}</span>
323
+ {% endif %}
324
+ <h6 class="card-title mb-1">
325
+ <a href="{{ lpost.url | relative_url }}" class="text-decoration-none text-body-emphasis">
326
+ {{ lpost.title | truncate: 45 }}
327
+ </a>
328
+ </h6>
329
+ <small class="text-muted">
330
+ <i class="bi bi-calendar me-1"></i>{{ lpost.date | date: "%b %d" }}
331
+ {% if lpost.featured %}
332
+ <span class="badge bg-warning text-dark ms-1">Featured</span>
333
+ {% endif %}
334
+ </small>
256
335
  </div>
336
+ </div>
337
+ </div>
338
+ </div>
339
+ </div>
340
+ {% endfor %}
341
+ </div>
342
+ </section>
257
343
 
258
- <!-- Categories Section -->
259
- <div class="p-4">
260
- {% include navigation/sidebar-categories.html %}
261
- </div>
344
+ <!-- ================================ -->
345
+ <!-- PAGE CONTENT (if any) -->
346
+ <!-- ================================ -->
347
+ {% if content != blank %}
348
+ <section class="page-content mb-5">
349
+ <div class="card border-0 shadow-sm">
350
+ <div class="card-body p-4 p-lg-5">
351
+ {{ content }}
352
+ </div>
353
+ </div>
354
+ </section>
355
+ {% endif %}
262
356
 
263
- <!-- External Links Section -->
264
- <div class="p-4">
265
- <h4 class="fst-italic">Elsewhere</h4>
266
- <ol class="list-unstyled">
267
- <li><a href="#">GitHub</a></li>
268
- <li><a href="#">Twitter</a></li>
269
- <li><a href="#">Facebook</a></li>
270
- </ol>
357
+ <!-- ================================ -->
358
+ <!-- TAGS & ARCHIVES -->
359
+ <!-- ================================ -->
360
+ <section class="footer-widgets mb-5">
361
+ <div class="row g-4">
362
+ <!-- Popular Tags -->
363
+ <div class="col-md-6">
364
+ <div class="card h-100 border-0 bg-body-tertiary">
365
+ <div class="card-body">
366
+ <h5 class="card-title mb-3">
367
+ <i class="bi bi-tags me-2"></i>Popular Tags
368
+ </h5>
369
+ {% assign all_tags = "" | split: "" %}
370
+ {% for post in site.posts %}
371
+ {% for tag in post.tags %}
372
+ {% assign all_tags = all_tags | push: tag %}
373
+ {% endfor %}
374
+ {% endfor %}
375
+ {% assign unique_tags = all_tags | uniq | slice: 0, 15 %}
376
+ <div class="d-flex flex-wrap gap-2">
377
+ {% for tag in unique_tags %}
378
+ <a href="{{ site.baseurl }}/tags/#{{ tag | slugify }}"
379
+ class="badge bg-secondary text-decoration-none fs-6">
380
+ {{ tag }}
381
+ </a>
382
+ {% endfor %}
383
+ </div>
384
+ <a href="{{ site.baseurl }}/tags/" class="btn btn-sm btn-outline-primary mt-3">
385
+ Browse All Tags <i class="bi bi-arrow-right ms-1"></i>
386
+ </a>
387
+ </div>
388
+ </div>
389
+ </div>
390
+
391
+ <!-- Archives -->
392
+ <div class="col-md-6">
393
+ <div class="card h-100 border-0 bg-body-tertiary">
394
+ <div class="card-body">
395
+ <h5 class="card-title mb-3">
396
+ <i class="bi bi-archive me-2"></i>Archives
397
+ </h5>
398
+ {% assign posts_by_year = site.posts | group_by_exp: "post", "post.date | date: '%Y'" %}
399
+ <div class="row">
400
+ {% for year in posts_by_year limit: 2 %}
401
+ <div class="col-6">
402
+ <h6 class="text-muted mb-2">{{ year.name }}</h6>
403
+ {% assign months = year.items | group_by_exp: "post", "post.date | date: '%B'" %}
404
+ <ul class="list-unstyled small">
405
+ {% for month in months limit: 6 %}
406
+ <li class="mb-1">
407
+ <a href="{{ '/archives/' | relative_url }}#{{ month.name | slugify }}-{{ year.name }}"
408
+ class="text-decoration-none">
409
+ {{ month.name }}
410
+ <span class="badge bg-light text-dark">{{ month.items.size }}</span>
411
+ </a>
412
+ </li>
413
+ {% endfor %}
414
+ </ul>
271
415
  </div>
416
+ {% endfor %}
272
417
  </div>
418
+ </div>
273
419
  </div>
420
+ </div>
274
421
  </div>
422
+ </section>
423
+
424
+ <!-- ================================ -->
425
+ <!-- NEWSLETTER SIGNUP -->
426
+ <!-- ================================ -->
427
+ <section class="newsletter-section mb-5">
428
+ <div class="card border-0 bg-primary text-white">
429
+ <div class="card-body p-4 p-lg-5 text-center">
430
+ <i class="bi bi-envelope-paper fs-1 mb-3 d-block"></i>
431
+ <h3 class="mb-3">Stay Updated</h3>
432
+ <p class="mb-4 opacity-75">Subscribe to get the latest news and updates delivered to your inbox.</p>
433
+ <form class="row g-2 justify-content-center">
434
+ <div class="col-md-4">
435
+ <input type="email" class="form-control form-control-lg" placeholder="Enter your email">
436
+ </div>
437
+ <div class="col-auto">
438
+ <button type="submit" class="btn btn-light btn-lg">
439
+ Subscribe <i class="bi bi-send ms-1"></i>
440
+ </button>
441
+ </div>
442
+ </form>
443
+ </div>
444
+ </div>
445
+ </section>
275
446
 
276
447
  </main>
277
448
 
449
+ <style>
450
+ .hover-lift {
451
+ transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
452
+ }
453
+ .hover-lift:hover {
454
+ transform: translateY(-4px);
455
+ box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
456
+ }
457
+ .card {
458
+ transition: transform 0.2s ease-in-out;
459
+ }
460
+ .hero-section img {
461
+ min-height: 300px;
462
+ }
463
+ @media (max-width: 767px) {
464
+ .hero-section img {
465
+ min-height: 200px;
466
+ }
467
+ }
468
+ </style>
469
+
278
470