151 lines
2.1 KiB
CSS
151 lines
2.1 KiB
CSS
html {
|
|
height: 100vh;
|
|
overflow: hidden;
|
|
}
|
|
|
|
body {
|
|
display: flex;
|
|
flex-direction: column;
|
|
height: 100vh;
|
|
overflow: hidden;
|
|
}
|
|
|
|
/* Fixed header and footer for list pages */
|
|
body:has(.content) header {
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
body:has(.content) footer {
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.main {
|
|
flex: 1;
|
|
overflow: hidden;
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.content {
|
|
width: 100%;
|
|
height: 100%;
|
|
padding: 40px;
|
|
box-sizing: border-box;
|
|
display: flex;
|
|
gap: 80px;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.topics {
|
|
font-size: 3em;
|
|
max-height: calc(100vh - 200px);
|
|
column-count: 2;
|
|
column-gap: 80px;
|
|
column-fill: auto;
|
|
margin: 0;
|
|
padding: 0;
|
|
list-style: none;
|
|
overflow-y: auto;
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
.topics::-webkit-scrollbar {
|
|
display: none;
|
|
}
|
|
|
|
.topics {
|
|
-ms-overflow-style: none;
|
|
scrollbar-width: none;
|
|
}
|
|
|
|
.topics li:first-child {
|
|
margin-top: 0;
|
|
}
|
|
|
|
.topics li:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.posts {
|
|
font-size: 2.2em;
|
|
text-align: right;
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: center;
|
|
min-height: 0;
|
|
}
|
|
|
|
.posts:empty {
|
|
display: none;
|
|
}
|
|
|
|
a {
|
|
text-decoration: none;
|
|
}
|
|
|
|
.post {
|
|
margin-bottom: 25px;
|
|
}
|
|
|
|
ul {
|
|
list-style: none;
|
|
margin: 0;
|
|
}
|
|
|
|
.topic a {
|
|
position: relative;
|
|
display: inline-block;
|
|
color: inherit;
|
|
text-decoration: none;
|
|
margin-bottom: 25px;
|
|
transition: color 0.5s ease;
|
|
}
|
|
|
|
.topic a::after {
|
|
content: "";
|
|
height: 2px;
|
|
display: block;
|
|
margin-top: 4px;
|
|
background: currentColor;
|
|
width: 0;
|
|
right: 100%;
|
|
position: absolute;
|
|
transition:
|
|
width 0.5s ease,
|
|
right 0.5s ease;
|
|
}
|
|
|
|
.topic a:hover::after,
|
|
.topic a.active::after {
|
|
width: 100%;
|
|
right: 0;
|
|
}
|
|
|
|
body:has(.topics:only-child) .content {
|
|
justify-content: flex-start;
|
|
}
|
|
|
|
body:has(.topics:only-child) .topics {
|
|
column-count: 2;
|
|
column-fill: auto;
|
|
max-width: 1200px;
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.topics {
|
|
font-size: 2em;
|
|
padding: 0 20px;
|
|
column-count: 1;
|
|
}
|
|
|
|
.posts {
|
|
font-size: 1.47em;
|
|
padding: 0 20px;
|
|
}
|
|
|
|
.topic a {
|
|
margin-bottom: 15px;
|
|
}
|
|
}
|