Files
wordpress-theme-aksrt/assets/css/frontend/widget-batch5.css
T
kate522 aabc1cd142 feat(widgets): deepen buttons, video player, recent comments
Add go_link/hollow/radius/icon slots for buttons; loop/poster/hide
controls for video player; exclude post/keywords on recent comments.
2026-07-19 01:17:41 +08:00

456 lines
12 KiB
CSS

/**
* Batch5: user card guest/login depth, main posts, term aggregation.
*/
.aksrt-user-card {
border-radius: 12px;
overflow: hidden;
border: 1px solid var(--color-line, #e5e7eb);
background: var(--surface-1, #fff);
text-align: center;
margin-bottom: 12px;
}
.aksrt-user-card__cover {
height: 90px;
background: linear-gradient(135deg, #93c5fd, #c4b5fd) center/cover no-repeat;
}
.aksrt-user-card__cover.is-empty {
background: linear-gradient(135deg, #e2e8f0, #f8fafc);
}
.aksrt-user-card__body { padding: 0 14px 16px; position: relative; }
.aksrt-user-card__checkin {
position: absolute;
right: 10px;
top: 8px;
z-index: 2;
max-width: 48%;
}
.aksrt-user-card__checkin .but {
padding: 4px 8px !important;
font-size: 12px !important;
line-height: 1.2;
}
.aksrt-user-card__checkin .aksrt-header-checkin-details { display: none; }
.aksrt-user-card__avatar {
display: inline-block;
margin-top: -36px;
width: 72px;
height: 72px;
border-radius: 50%;
overflow: hidden;
border: 3px solid var(--surface-1, #fff);
background: var(--surface-2, #eee);
}
.aksrt-user-card__avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.aksrt-user-card__name {
margin: 10px 0 0;
font-size: 16px;
font-weight: 700;
}
.aksrt-user-card__name a { color: inherit; text-decoration: none; }
.aksrt-user-card__bio,
.aksrt-user-card__guest-title {
margin: 8px 0 0;
font-size: 12px;
color: var(--muted-2-color, #888);
line-height: 1.5;
}
.aksrt-user-card__guest-title { font-size: 14px; font-weight: 600; color: inherit; }
.aksrt-user-card__stats {
display: flex;
justify-content: center;
gap: 18px;
margin-top: 12px;
}
.aksrt-user-card__stat-value {
display: block;
font-size: 16px;
font-weight: 700;
}
.aksrt-user-card__stat-label {
font-size: 11px;
color: var(--muted-2-color, #999);
}
.aksrt-user-card__actions {
display: flex;
justify-content: center;
flex-wrap: wrap;
gap: 8px;
margin-top: 14px;
}
.aksrt-user-card__btn {
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 96px;
padding: 7px 14px;
border-radius: 999px;
font-size: 13px;
text-decoration: none;
font-weight: 600;
}
.aksrt-user-card__btn--primary {
background: var(--color-primary, #3b82f6);
color: #fff !important;
}
.aksrt-user-card__btn--ghost {
background: var(--surface-2, #f3f4f6);
color: inherit !important;
}
/* Main posts */
.aksrt-main-posts { display: flex; flex-direction: column; gap: 10px; }
.aksrt-main-posts.style-card {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 12px;
}
@media (max-width: 575.98px) {
.aksrt-main-posts.style-card { grid-template-columns: 1fr; }
}
.aksrt-main-posts__card {
display: block;
border-radius: 12px;
overflow: hidden;
border: 1px solid var(--color-line, #e5e7eb);
background: var(--surface-1, #fff);
text-decoration: none;
color: inherit;
}
.aksrt-main-posts__thumb {
height: 110px;
background: var(--surface-2, #f3f4f6);
overflow: hidden;
}
.aksrt-main-posts__thumb.mini {
width: 56px;
height: 56px;
border-radius: 8px;
flex-shrink: 0;
}
.aksrt-main-posts__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.aksrt-main-posts__thumb.is-empty { background: linear-gradient(135deg, #e2e8f0, #f8fafc); }
.aksrt-main-posts__body { padding: 10px 12px 12px; min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.aksrt-main-posts__title {
font-size: 13px;
font-weight: 600;
line-height: 1.4;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}
.aksrt-main-posts__meta {
display: flex;
gap: 10px;
font-size: 11px;
color: var(--muted-2-color, #999);
}
.aksrt-main-posts__row {
display: flex;
align-items: center;
gap: 10px;
text-decoration: none;
color: inherit;
padding: 4px 0;
border-bottom: 1px dashed var(--color-line, #e5e7eb);
}
.aksrt-main-posts__row:last-child { border-bottom: 0; }
.aksrt-main-posts__num {
width: 20px;
flex-shrink: 0;
font-size: 12px;
font-weight: 700;
color: var(--color-primary, #3b82f6);
text-align: center;
}
/* Term aggregation */
.aksrt-term-agg {
display: grid;
grid-template-columns: repeat(var(--aksrt-ta-cols, 1), minmax(0, 1fr));
gap: 12px;
}
.aksrt-term-agg__card {
border: 1px solid var(--color-line, #e5e7eb);
border-radius: 12px;
overflow: hidden;
background: var(--surface-1, #fff);
}
.aksrt-term-agg__head {
display: block;
text-decoration: none;
color: inherit;
position: relative;
}
.aksrt-term-agg__cover {
height: 96px;
background: var(--surface-2, #f3f4f6) center/cover no-repeat;
}
.aksrt-term-agg__cover.is-empty {
background: linear-gradient(135deg, #dbeafe, #eff6ff);
}
.aksrt-term-agg__name {
position: absolute;
left: 12px;
bottom: 10px;
font-weight: 700;
color: #fff;
text-shadow: 0 1px 3px rgba(0,0,0,.45);
}
.aksrt-term-agg__count {
position: absolute;
right: 10px;
top: 10px;
font-size: 11px;
padding: 2px 8px;
border-radius: 999px;
background: rgba(0,0,0,.45);
color: #fff;
}
.aksrt-term-agg__posts {
list-style: none;
margin: 0;
padding: 8px 12px 10px;
}
.aksrt-term-agg__posts li {
padding: 6px 0;
border-bottom: 1px dashed var(--color-line, #eee);
}
.aksrt-term-agg__posts li:last-child { border-bottom: 0; }
.aksrt-term-agg__posts a {
color: inherit;
text-decoration: none;
font-size: 13px;
display: block;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
/* Icon cover cards */
.aksrt-icon-cover {
display: grid;
grid-template-columns: repeat(var(--aksrt-icc-pc, 2), minmax(0, 1fr));
gap: 10px;
--aksrt-icc-icon: 25px;
}
@media (max-width: 575.98px) {
.aksrt-icon-cover {
grid-template-columns: repeat(var(--aksrt-icc-m, 1), minmax(0, 1fr));
}
}
.aksrt-icon-cover__item {
display: flex;
align-items: center;
gap: 10px;
padding: 12px;
border-radius: 12px;
border: 1px solid var(--color-line, #e5e7eb);
background: var(--surface-1, #fff);
text-decoration: none;
color: inherit;
}
.aksrt-icon-cover__icon {
width: calc(var(--aksrt-icc-icon) + 18px);
height: calc(var(--aksrt-icc-icon) + 18px);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-size: var(--aksrt-icc-icon);
color: var(--color-primary, #3b82f6);
background: var(--surface-2, #f3f4f6);
flex-shrink: 0;
overflow: hidden;
}
.aksrt-icon-cover.is-radius .aksrt-icon-cover__icon { border-radius: 10px; }
.aksrt-icon-cover__icon img { width: 70%; height: 70%; object-fit: contain; }
.aksrt-icon-cover__title { font-weight: 700; font-size: 14px; }
.aksrt-icon-cover__desc { font-size: 12px; color: var(--muted-2-color, #888); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Bookmark links */
.aksrt-bookmark-links {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 10px;
}
.aksrt-bookmark-links.has-box {
padding: 10px;
border: 1px solid var(--color-line, #e5e7eb);
border-radius: 12px;
}
.aksrt-bookmark-links.style-simple {
grid-template-columns: 1fr;
}
.aksrt-bookmark-links__item {
display: flex;
align-items: center;
gap: 10px;
padding: 8px;
border-radius: 10px;
background: var(--surface-2, #f8fafc);
text-decoration: none;
color: inherit;
min-width: 0;
}
.aksrt-bookmark-links__img {
width: 36px;
height: 36px;
border-radius: 8px;
object-fit: cover;
flex-shrink: 0;
}
.aksrt-bookmark-links__text { min-width: 0; display: flex; flex-direction: column; }
.aksrt-bookmark-links__name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aksrt-bookmark-links__desc { font-size: 11px; color: var(--muted-2-color, #999); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Search keywords */
.aksrt-search-widget__keywords { margin-top: 10px; }
.aksrt-search-widget__kw-title {
font-size: 12px;
color: var(--muted-2-color, #888);
margin-bottom: 6px;
}
.aksrt-search-widget__kw-list { display: flex; flex-wrap: wrap; gap: 6px; }
.aksrt-search-widget__kw {
display: inline-block;
padding: 3px 10px;
border-radius: 999px;
background: var(--surface-2, #f3f4f6);
color: inherit;
text-decoration: none;
font-size: 12px;
}
.aksrt-search-widget__more { margin-top: 8px; text-align: right; font-size: 12px; }
.aksrt-search-widget__more a { color: var(--color-primary, #3b82f6); text-decoration: none; }
/* Scroll notice */
.aksrt-scroll-notice {
display: flex;
align-items: center;
gap: 10px;
padding: 10px 14px;
border-radius: 10px;
background: #eff6ff;
color: #1d4ed8;
margin-bottom: 8px;
overflow: hidden;
}
.aksrt-scroll-notice.is-radius { border-radius: 999px; }
.aksrt-scroll-notice.color-c-green { background: #ecfdf5; color: #047857; }
.aksrt-scroll-notice.color-c-yellow { background: #fffbeb; color: #b45309; }
.aksrt-scroll-notice.color-c-red { background: #fef2f2; color: #b91c1c; }
.aksrt-scroll-notice.color-c-purple { background: #f5f3ff; color: #6d28d9; }
.aksrt-scroll-notice__icon { flex-shrink: 0; }
.aksrt-scroll-notice__viewport { position: relative; flex: 1; min-width: 0; height: 1.4em; }
.aksrt-scroll-notice__item {
position: absolute;
inset: 0;
opacity: 0;
transform: translateY(8px);
transition: opacity .35s ease, transform .35s ease;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
font-size: 13px;
line-height: 1.4;
}
.aksrt-scroll-notice__item.is-active {
opacity: 1;
transform: translateY(0);
}
.aksrt-scroll-notice__item a {
color: inherit;
text-decoration: none;
}
.aksrt-scroll-notice__item i { margin-right: 6px; opacity: .85; }
.hot-post-item { display: flex; align-items: center; gap: 10px; }
.hot-post-item__thumb {
width: 48px; height: 48px; border-radius: 8px; overflow: hidden; flex-shrink: 0;
background: var(--surface-2, #eee);
}
.hot-post-item__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.aksrt-cover-card__bg.is-video video {
width: 100%; height: 100%; object-fit: cover; display: block;
}
.widget-buttons {
display: flex;
flex-wrap: wrap;
gap: var(--btn-gap, 10px);
margin-bottom: 8px;
}
.widget-buttons--vertical { flex-direction: column; }
.widget-buttons.align-center { justify-content: center; }
.widget-buttons.align-left { justify-content: flex-start; }
.widget-buttons.align-right { justify-content: flex-end; }
.widget-buttons__btn {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 6px;
padding: 8px 16px;
border-radius: 8px;
text-decoration: none;
font-size: 13px;
font-weight: 600;
background: var(--color-primary, #3b82f6);
color: #fff !important;
}
.widget-buttons.is-radius .widget-buttons__btn { border-radius: 999px; }
.widget-buttons.is-hollow .widget-buttons__btn {
background: transparent;
color: var(--color-primary, #3b82f6) !important;
border: 1px solid currentColor;
}
.widget-buttons__btn--secondary { background: #64748b; }
.widget-buttons__btn--outline {
background: transparent;
color: inherit !important;
border: 1px solid var(--color-line, #ddd);
}
.widget-buttons__btn--text {
background: transparent;
color: var(--color-primary, #3b82f6) !important;
padding-left: 0;
padding-right: 0;
}
.widget-buttons__btn--pink { background: #ec4899; }
.widget-buttons__btn--blue { background: #3b82f6; }
.widget-buttons__btn--green { background: #22c55e; }
.aksrt-video-widget {
position: relative;
width: 100%;
height: 0;
border-radius: 8px;
overflow: hidden;
background: #111;
margin-bottom: 10px;
}
.aksrt-video-widget iframe,
.aksrt-video-widget video {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
border: 0;
object-fit: cover;
}
.aksrt-video-widget.controller-hide video::-webkit-media-controls {
display: none !important;
}
.widget-recent-comments__post {
margin-top: 2px;
font-size: 11px;
}
.widget-recent-comments__post a {
color: var(--muted-2-color, #999);
text-decoration: none;
}