Skip to content

Commit 339c797

Browse files
authored
Merge pull request #120 from CloudNativeLinz/fix/116
Enhance tablet responsiveness with new mixins and styling adjustments
2 parents 675e39f + ebd9c90 commit 339c797

File tree

1 file changed

+111
-6
lines changed

1 file changed

+111
-6
lines changed

assets/style.scss

Lines changed: 111 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,27 @@
44
// Use SVG icons
55
@use 'svg-icons';
66

7-
/* Modern 2025 Design System - Cloud Native Linz */
8-
97
// Mobile mixin
108
@mixin mobile {
119
@media screen and (max-width: 640px) {
1210
@content;
1311
}
1412
}
1513

14+
// Tablet mixin
15+
@mixin tablet {
16+
@media screen and (min-width: 641px) and (max-width: 1024px) {
17+
@content;
18+
}
19+
}
20+
21+
// Mobile and Tablet combined (for menu behavior)
22+
@mixin mobile-tablet {
23+
@media screen and (max-width: 1024px) {
24+
@content;
25+
}
26+
}
27+
1628
/* Base Reset */
1729
* {
1830
box-sizing: border-box;
@@ -44,6 +56,21 @@ h4 { font-size: 1.25rem; }
4456
h5 { font-size: 1.125rem; }
4557
h6 { font-size: 1rem; }
4658

59+
/* Tablet-specific typography */
60+
@media (min-width: 641px) and (max-width: 1024px) {
61+
body {
62+
font-size: 1.0625rem;
63+
line-height: 1.65;
64+
}
65+
66+
h1 { font-size: 2.5rem; }
67+
h2 { font-size: 2rem; }
68+
h3 { font-size: 1.625rem; }
69+
h4 { font-size: 1.375rem; }
70+
h5 { font-size: 1.1875rem; }
71+
h6 { font-size: 1.0625rem; }
72+
}
73+
4774
p { margin-bottom: 1rem; }
4875

4976
a {
@@ -63,6 +90,13 @@ a:hover {
6390
padding: 0 1rem;
6491
}
6592

93+
/* Tablet-specific container adjustments */
94+
@media (min-width: 641px) and (max-width: 1024px) {
95+
.container {
96+
padding: 0 1.5rem;
97+
}
98+
}
99+
66100
/* Gradient bar */
67101
.gradient-bar {
68102
height: 4px;
@@ -79,6 +113,13 @@ a:hover {
79113
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
80114
}
81115

116+
/* Tablet-specific header adjustments */
117+
@media (min-width: 641px) and (max-width: 1024px) {
118+
.site-header {
119+
padding: 1.25rem 0;
120+
}
121+
}
122+
82123
.header-content {
83124
display: flex;
84125
justify-content: space-between;
@@ -104,6 +145,18 @@ a:hover {
104145
border: 2px solid rgba(255, 255, 255, 0.3);
105146
}
106147

148+
/* Tablet-specific logo adjustments */
149+
@media (min-width: 641px) and (max-width: 1024px) {
150+
.site-logo img {
151+
width: 55px;
152+
height: 55px;
153+
}
154+
155+
.site-logo {
156+
gap: 1.25rem;
157+
}
158+
}
159+
107160
.site-info {
108161
display: flex;
109162
flex-direction: column;
@@ -124,13 +177,24 @@ a:hover {
124177
font-weight: 400;
125178
}
126179

180+
/* Tablet-specific typography improvements */
181+
@media (min-width: 641px) and (max-width: 1024px) {
182+
.site-name {
183+
font-size: 1.625rem;
184+
}
185+
186+
.site-description {
187+
font-size: 0.9375rem;
188+
}
189+
}
190+
127191
/* Navigation */
128192
.site-nav {
129193
display: none;
130194
gap: 1.1rem;
131195
}
132196

133-
@media (min-width: 768px) {
197+
@media (min-width: 1025px) {
134198
.site-nav {
135199
display: flex;
136200
}
@@ -187,7 +251,21 @@ a:hover {
187251
z-index: 10;
188252
}
189253

190-
@media (min-width: 768px) {
254+
/* Tablet-specific mobile menu button */
255+
@media (min-width: 641px) and (max-width: 1024px) {
256+
.mobile-menu-btn {
257+
width: 2.25rem;
258+
height: 2.25rem;
259+
padding: 0.125rem; /* Add small padding for better touch target */
260+
}
261+
262+
.hamburger-line {
263+
width: 2rem;
264+
height: 0.25rem;
265+
}
266+
}
267+
268+
@media (min-width: 1025px) {
191269
.mobile-menu-btn {
192270
display: none;
193271
}
@@ -215,8 +293,8 @@ a:hover {
215293
transform: rotate(-45deg);
216294
}
217295

218-
/* Mobile Navigation */
219-
@media (max-width: 767px) {
296+
/* Mobile and Tablet Navigation */
297+
@media (max-width: 1024px) {
220298
.site-nav {
221299
position: absolute;
222300
top: 100%;
@@ -248,17 +326,44 @@ a:hover {
248326
}
249327
}
250328

329+
/* Tablet-specific navigation improvements */
330+
@media (min-width: 641px) and (max-width: 1024px) {
331+
.site-nav {
332+
padding: 1.25rem;
333+
}
334+
335+
.nav-link {
336+
padding: 0.875rem 1.25rem;
337+
font-size: 1.0625rem;
338+
min-height: 48px; /* Better touch target for tablets */
339+
}
340+
}
341+
251342
/* Main Content */
252343
.site-main {
253344
padding: 2rem 0;
254345
}
255346

347+
/* Tablet-specific main content improvements */
348+
@media (min-width: 641px) and (max-width: 1024px) {
349+
.site-main {
350+
padding: 2.5rem 0;
351+
}
352+
}
353+
256354
.page-content {
257355
max-width: 1200px;
258356
margin: 0 auto;
259357
padding: 0 1rem;
260358
}
261359

360+
/* Tablet-specific page content improvements */
361+
@media (min-width: 641px) and (max-width: 1024px) {
362+
.page-content {
363+
padding: 0 1.5rem;
364+
}
365+
}
366+
262367
/* Cards */
263368
.card {
264369
background: white;

0 commit comments

Comments
 (0)