Files
PC-Light-Forum/css/search.css
DESKTOP-RQ919RC\Pc ea6ae8d7fc fix(homepage): 修复个人主页样式和功能问题
修复个人主页的响应式布局问题,优化移动端显示效果
调整分类和排序区域的样式,移除不必要的margin-left
更新投票组件的内容显示类名为one-line-display-v2
修复主页加载逻辑,优化数据获取和分页处理
移除未使用的代码和注释,清理CSS样式
2025-12-26 18:50:05 +08:00

423 lines
9.0 KiB
CSS

#search {
max-width: 1200px;
margin: 0 auto;
min-width: 320px;
}
#search .search-box {
width: 460px;
height: 48px;
background-color: #ffffff;
border: 1px solid #d7d7d7;
border-radius: 10px;
padding: 0 16px;
margin-bottom: 20px;
}
#search .search-box .search-input {
border: none;
outline: none;
height: 100%;
font-size: 16px;
}
#search .search-box .search-icon {
width: 20px;
height: 20px;
cursor: pointer;
}
#search .classify {
margin-bottom: 16px;
}
#search .classify .item {
min-width: 50px;
padding: 0 8px;
height: 32px;
line-height: 32px;
text-align: center;
background-color: #ffffff;
border: 1px solid #f2f2f2;
border-radius: 12px;
color: #333333;
cursor: pointer;
font-size: 15px;
}
#search .classify .item.pitch {
background-color: #d35110;
color: #ffffff;
}
#search .classify .item:not(:last-child) {
margin-right: 10px;
}
#search .quantity {
font-size: 14px;
line-height: 26px;
color: #555;
margin-bottom: 14px;
}
#search .quantity .line {
width: 1px;
height: 14px;
background-color: #aaaaaa;
margin: 0 10px;
}
#search .quantity .num {
font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif;
font-weight: 650;
color: #000000;
margin: 0 10px;
}
#search .quantity .sort-area {
position: relative;
z-index: 1;
}
#search .quantity .sort-area .sort-head {
cursor: pointer;
}
#search .quantity .sort-area .sort-head .text {
font-size: 14px;
color: #555555;
line-height: 26px;
margin-right: 6px;
}
#search .quantity .sort-area .sort-head .icon {
width: 8px;
height: 5px;
transform: rotate(0deg);
transition: transform 0.3s ease-in-out;
}
#search .quantity .sort-area .sort-head .icon.rotate {
transform: rotate(180deg);
}
#search .quantity .sort-area .sort-mask {
position: fixed;
top: 0;
left: 0;
width: 100vw;
height: 100vh;
}
#search .quantity .sort-area .sort-box {
position: absolute;
top: 28px;
right: 0;
width: 140px;
padding: 0 10px;
background-color: #ffffff;
border-radius: 8px;
box-shadow: 0 0 5px rgba(0, 0, 0, 0.16862745);
}
#search .quantity .sort-area .sort-box .item {
font-size: 16px;
color: #555555;
text-align: center;
height: 60px;
line-height: 60px;
cursor: pointer;
}
#search .quantity .sort-area .sort-box .item.pitch {
font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif;
font-weight: 650;
font-style: normal;
color: #d35110;
}
#search .quantity .sort-area .sort-box .item:not(:last-child) {
border-bottom: 1px dotted #d7d7d7;
}
#search .matter {
align-items: flex-start;
}
#search .matter.bottom {
align-items: flex-end;
}
#search .matter .matter-content {
min-width: 0;
margin-right: 12px;
position: sticky;
z-index: 1;
}
#search .matter .matter-content .list-box .item-box {
margin-bottom: 12px;
}
#search .matter .matter-content .empty {
width: 100%;
height: 70vh;
background-color: #ffffff;
border: 1px solid #e9eef2;
border-radius: 10px;
flex-direction: column;
margin-right: 12px;
}
#search .matter .matter-content .empty .empty-icon {
width: 80px;
height: 94px;
}
#search .matter .matter-content .empty .empty-text {
font-size: 14px;
color: #7f7f7f;
margin-top: 10px;
}
#search .matter .matter-content .pages-box {
padding-bottom: 60px;
padding-top: 30px;
}
#search .matter .matter-content .pages-box .item {
min-width: 24px;
height: 24px;
line-height: 24px;
text-align: center;
border-radius: 50px;
font-size: 14px;
color: #555555;
cursor: pointer;
padding: 0 4px;
}
#search .matter .matter-content .pages-box .item.pitch {
background-color: #6fc16d;
color: #ffffff;
}
#search .matter .matter-content .pages-box .arrows {
width: 7px;
height: 12px;
margin: 0 30px;
cursor: pointer;
}
#search .matter .matter-content .pages-box .arrows.rotate180 {
transform: rotate(180deg);
}
#search .matter .sidebar-box {
width: 291px;
position: sticky;
}
#search .matter .sidebar-box .recommend-and-essence {
width: 291px;
height: 64px;
background-color: #ffffff;
border: 1px solid #e9eef2;
border-radius: 10px;
padding: 0 10px;
justify-content: space-between;
margin-bottom: 12px;
}
#search .matter .sidebar-box .recommend-and-essence .item {
width: 130px;
height: 40px;
background-color: #f6f6f6;
border: 1px solid #f2f2f2;
border-radius: 65px;
font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif;
font-weight: 650;
font-style: normal;
font-size: 16px;
color: #000000;
cursor: pointer;
}
#search .matter .sidebar-box .recommend-and-essence .item .icon {
width: 20px;
height: 24px;
margin-right: 8px;
}
#search .search-no {
padding-bottom: 30px;
}
#search .search-no .earth-icon {
width: 239px;
height: 180px;
margin: 0 auto 20px;
}
#search .search-no .input-box {
max-width: 903px;
width: 100%;
height: 60px;
background-color: #ffffff;
border: 1px solid #e9eef2;
border-radius: 6px;
margin: 0 auto 30px;
padding-right: 10px;
}
#search .search-no .input-box .input {
font-size: 16px;
border: none;
outline: none;
height: 100%;
padding: 0 15px;
border-radius: 6px;
}
#search .search-no .input-box .btn {
width: 120px;
height: 40px;
line-height: 40px;
text-align: center;
background-color: #d35110;
border-radius: 8px;
font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif;
font-weight: 650;
font-style: normal;
font-size: 16px;
color: #ffffff;
cursor: pointer;
}
#search .search-no .recommend-box {
max-width: 903px;
width: 100%;
gap: 10px;
margin: 0 auto;
}
#search .search-no .recommend-box .recommend-head {
font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif;
font-weight: 650;
font-style: normal;
font-size: 16px;
color: #000000;
margin-bottom: 15px;
}
#search .search-no .recommend-box .recommend-head .icon {
width: 10px;
height: 18px;
margin-right: 10px;
}
#search .search-no .recommend-box .hot-box {
width: 100%;
min-width: 0;
background-color: #ffffff;
border: 1px solid #e9eef2;
border-radius: 10px;
padding-top: 20px;
padding-bottom: 12px;
}
#search .search-no .recommend-box .hot-box .hot-list {
flex-wrap: wrap;
padding-left: 20px;
padding-right: 12px;
}
#search .search-no .recommend-box .hot-box .hot-list .item {
font-size: 14px;
color: #333333;
height: 32px;
line-height: 32px;
padding: 0 13px;
margin-bottom: 10px;
background-color: #f6f6f6;
border: 1px solid #f2f2f2;
border-radius: 16px;
margin-right: 8px;
cursor: pointer;
}
#search .search-no .recommend-box .hot-box .hot-list .item .icon {
width: 17px;
height: 20px;
margin-right: 5px;
}
#search .search-no .recommend-box .read-box {
width: 100%;
min-width: 0;
background-color: #ffffff;
border: 1px solid #e9eef2;
border-radius: 10px;
padding-top: 20px;
padding-bottom: 12px;
}
#search .search-no .recommend-box .read-box .read-list {
padding-left: 20px;
padding-right: 12px;
}
#search .search-no .recommend-box .read-box .read-list .item {
font-size: 14px;
color: #555555;
cursor: pointer;
}
#search .search-no .recommend-box .read-box .read-list .item:hover {
color: #000000;
}
#search .search-no .recommend-box .read-box .read-list .item:not(:last-of-type) {
margin-bottom: 12px;
}
#search .search-no .recommend-box .read-box .read-list .item .dot {
width: 6px;
height: 6px;
border-radius: 50%;
background-color: #86d0b1;
border: 1px solid #239f6c;
margin-right: 10px;
}
@media screen and (max-width: 768px) {
#search .search-box {
width: auto !important;
height: 40px !important;
}
#search .matter .matter-content {
margin: 0;
}
#search .matter .sidebar-box {
display: none;
}
#search .matter .search-box {
margin-left: 10px;
margin-right: 10px;
}
#search {
padding: 0 10px;
}
#search .search-no .earth-icon {
width: 60%;
max-width: 220px;
height: auto;
margin-bottom: 10px;
}
#search .search-no .input-box {
width: 100%;
height: 48px;
margin-bottom: 20px;
}
#search .search-no .input-box .btn {
width: 80px;
height: 36px;
line-height: 36px;
font-size: 14px;
}
#search .search-no .recommend-box {
width: 100%;
flex-direction: column;
height: auto;
}
#search .search-no .recommend-box .hot-box,
#search .search-no .recommend-box .read-box {
width: 100%;
}
.main-new {
width: 100%;
flex-direction: column;
}
.main-new .wp {
width: 100%;
min-width: 100%;
margin-right: 0;
}
.main-new .rightright {
width: 100%;
}
.item-box {
padding: 15px 10px 0;
}
.side-box {
width: 100%;
}
.head-top .input-box {
width: 100%;
}
.head-top .input-box .placeholder {
width: 100%;
}
}
@media screen and (max-width: 500px) {
#search .classify .item {
min-width: inherit;
font-size: 13px;
height: 28px;
line-height: 28px;
border-radius: 8px;
}
}
@media screen and (max-width: 450px) {
#search .classify .item {
padding: 0 5px;
margin-right: 5px !important;
}
}