misuzu/assets/misuzu.css/forum/categories.css

232 lines
No EOL
4.6 KiB
CSS

.forum__categories {
margin: 2px 0;
box-sizing: content-box;
overflow: auto;
}
.forum__categories__empty {
font-size: 1.2em;
line-height: 1.5em;
text-align: center;
padding: 10px;
}
.forum__categories__list {
display: flex;
flex-direction: column;
margin: 5px;
overflow: hidden;
}
.forum__category {
border-radius: 2px;
background-color: rgba(17, 17, 17, .6);
transition: background-color .2s, box-shadow .2s;
}
.forum__category:nth-child(even) {
background-color: rgba(25, 25, 25, .6);
}
.forum__category:hover,
.forum__category:focus {
background-color: #2229;
box-shadow: 0 1px 4px #222;
}
.forum__category:not(:last-child) {
margin-bottom: 4px;
}
.forum__category__link {
display: block;
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
color: inherit;
text-decoration: none;
}
.forum__category__container {
display: flex;
padding: 5px;
align-items: center;
min-height: 50px;
pointer-events: none;
}
.forum__category__icon {
flex: 0 0 40px;
border-radius: 2px;
width: 40px;
height: 40px;
margin-right: 4px;
background-color: #333;
background-size: 80px 80px;
background-image: radial-gradient(ellipse at center, rgba(255, 255, 255, .2) 0%, rgba(0, 0, 0, .4) 100%);
box-shadow: 0 1px 4px #111;
font-size: 2em;
line-height: 1.5em;
color: #fff;
display: flex;
justify-content: center;
align-items: center;
padding-bottom: 1px; /* fixes centering */
}
.forum__category__icon--unread {
background-color: var(--accent-colour);
}
.forum__category__details {
margin: 0 4px;
flex: 1 1 auto;
display: flex;
justify-content: center;
flex-direction: column;
line-height: 1.5em;
}
.forum__category__title {
font-size: 1.3em;
}
.forum__category__description,
.forum__category__subforums {
font-size: .9em;
}
.forum__category__subforums {
display: flex;
}
.forum__category__subforum {
padding: 2px;
pointer-events: initial;
color: var(--accent-colour);
text-decoration: none;
}
.forum__category__subforum:hover,
.forum__category__subforum:focus {
text-decoration: underline;
}
.forum__category__subforum--unread {
font-weight: 700;
}
.forum__category__stats,
.forum__category__activity {
display: flex;
flex: 0 0 auto;
}
.forum__category__stats {
text-align: center;
min-width: 100px;
flex-direction: column;
}
.forum__category__stat {
font-size: .9em;
line-height: 1.3em;
opacity: .7;
pointer-events: auto;
}
.forum__category__stat:first-child {
font-size: 1.5em;
opacity: 1;
}
.forum__category__activity {
text-align: right;
min-width: 270px;
line-height: 1.5em;
}
.forum__category__activity__none,
.forum__category__activity__details {
margin: 0 8px;
flex: 1 1 auto;
}
.forum__category__activity__details {
display: flex;
flex-direction: column;
align-items: flex-end;
}
.forum__category__activity__post {
color: var(--accent-colour);
text-decoration: none;
pointer-events: initial;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
max-width: 200px;
}
.forum__category__activity__post:hover,
.forum__category__activity__post:focus {
text-decoration: underline;
}
.forum__category__username {
color: var(--user-colour);
text-decoration: none;
pointer-events: initial;
}
.forum__category__username:hover,
.forum__category__username:focus {
text-decoration: underline;
}
.forum__category__avatar {
display: block;
flex: 0 0 auto;
text-decoration: none;
color: inherit;
width: 40px;
height: 40px;
pointer-events: initial;
}
@media (max-width: 800px) {
.forum__category__container {
flex-wrap: wrap;
}
.forum__category__details {
flex-basis: calc(100% - 100px);
}
.forum__category__stats {
min-width: initial;
border-left-width: 0;
align-self: flex-start;
align-items: flex-end;
}
.forum__category__stat {
font-size: 1em;
margin: 0 4px;
}
.forum__category__activity {
min-width: 100%;
}
.forum__category__activity--empty {
display: none;
}
.forum__category__activity__none,
.forum__category__activity__details {
margin: 1px 4px 0;
}
.forum__category__activity__details {
flex-direction: row;
}
.forum__category__activity__post {
flex: 1 0 auto;
text-align: left;
max-width: 120px;
}
.forum__category__activity__info {
width: 100%;
}
.forum__category__avatar {
display: none;
}
}