|
|
@@ -0,0 +1,404 @@
|
|
|
+/**index.wxss**/
|
|
|
+page {
|
|
|
+ font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica,
|
|
|
+ "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
|
|
|
+ color: #333;
|
|
|
+ min-height: 100vh;
|
|
|
+}
|
|
|
+
|
|
|
+.container {
|
|
|
+ width: 100%;
|
|
|
+ min-height: 100vh;
|
|
|
+ padding-bottom: 100rpx;
|
|
|
+ box-sizing: border-box;
|
|
|
+ position: relative;
|
|
|
+}
|
|
|
+
|
|
|
+/* 状态栏占位 */
|
|
|
+.status-bar {
|
|
|
+ height: 40rpx;
|
|
|
+ width: 100%;
|
|
|
+}
|
|
|
+
|
|
|
+/* 头部区域 */
|
|
|
+.header {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ padding: 0 30rpx;
|
|
|
+ height: 100rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.avatar {
|
|
|
+ width: 60rpx;
|
|
|
+ height: 60rpx;
|
|
|
+ border-radius: 50%;
|
|
|
+ overflow: hidden;
|
|
|
+}
|
|
|
+
|
|
|
+.avatar image {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+}
|
|
|
+
|
|
|
+.icon-more,
|
|
|
+.icon-search {
|
|
|
+ width: 50rpx;
|
|
|
+ height: 50rpx;
|
|
|
+ margin-left: 30rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.icon-more image,
|
|
|
+.icon-search image {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+}
|
|
|
+
|
|
|
+.main-wrapper {
|
|
|
+ width: 100vw;
|
|
|
+ background: linear-gradient(to right,
|
|
|
+ rgba(247, 244, 241, 1) 0%,
|
|
|
+ rgba(247, 244, 241, 0.8) 20%,
|
|
|
+ rgba(247, 244, 241, 0.6) 40%,
|
|
|
+ rgba(247, 244, 241, 0.4) 60%,
|
|
|
+ rgba(247, 244, 241, 0.2) 80%,
|
|
|
+ rgba(247, 244, 241, 0) 100%
|
|
|
+ );
|
|
|
+ position: relative;
|
|
|
+ overflow: hidden;
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+/* 性别和搜索 */
|
|
|
+.tab-search {
|
|
|
+ padding: 30rpx 30rpx 0 30rpx;
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+}
|
|
|
+
|
|
|
+.gender-tabs {
|
|
|
+ display: flex;
|
|
|
+ margin-bottom: 20rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.tab {
|
|
|
+ font-size: 30rpx;
|
|
|
+ margin-right: 40rpx;
|
|
|
+ padding: 10rpx 0;
|
|
|
+ position: relative;
|
|
|
+ color: #999;
|
|
|
+}
|
|
|
+
|
|
|
+.tab.active {
|
|
|
+ color: #333;
|
|
|
+ font-weight: bold;
|
|
|
+}
|
|
|
+
|
|
|
+.tab.active:after {
|
|
|
+ content: "";
|
|
|
+ position: absolute;
|
|
|
+ bottom: 0;
|
|
|
+ left: 50%;
|
|
|
+ transform: translateX(-50%);
|
|
|
+ width: 40rpx;
|
|
|
+ height: 6rpx;
|
|
|
+ background: linear-gradient(to right, #007aff, #af97ed);
|
|
|
+ border-radius: 3rpx;
|
|
|
+}
|
|
|
+
|
|
|
+/* 搜索框 */
|
|
|
+.search-box {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ height: 70rpx;
|
|
|
+ background-color: #fff;
|
|
|
+ border-radius: 35rpx;
|
|
|
+ padding: 0 30rpx;
|
|
|
+ width: 400rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.search-box icon {
|
|
|
+ margin-right: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.search-box input {
|
|
|
+ flex: 1;
|
|
|
+ height: 100%;
|
|
|
+ font-size: 28rpx;
|
|
|
+ color: #999;
|
|
|
+}
|
|
|
+
|
|
|
+/* 主Banner */
|
|
|
+.main-banner {
|
|
|
+ width: 100%;
|
|
|
+ height: 260rpx;
|
|
|
+ padding: 20rpx 30rpx;
|
|
|
+ box-sizing: border-box;
|
|
|
+}
|
|
|
+
|
|
|
+.main-banner image {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ border-radius: 20rpx;
|
|
|
+}
|
|
|
+
|
|
|
+/* 功能区 */
|
|
|
+.feature-section {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-around;
|
|
|
+ padding: 30rpx;
|
|
|
+ background-color: #fff;
|
|
|
+ border-radius: 20rpx;
|
|
|
+ margin: 20rpx 30rpx 30rpx;
|
|
|
+ box-shadow: 0 4rpx 10rpx rgba(0, 0, 0, 0.05);
|
|
|
+}
|
|
|
+
|
|
|
+.feature-item {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+}
|
|
|
+
|
|
|
+.feature-item image {
|
|
|
+ width: 80rpx;
|
|
|
+ height: 80rpx;
|
|
|
+ margin-bottom: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.feature-item text {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #666;
|
|
|
+}
|
|
|
+
|
|
|
+/* 公共区域标题 */
|
|
|
+.section-header {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ padding: 30rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.section-header .title {
|
|
|
+ font-size: 34rpx;
|
|
|
+ font-weight: bold;
|
|
|
+}
|
|
|
+
|
|
|
+.section-header .more {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #999;
|
|
|
+}
|
|
|
+
|
|
|
+/* 主编推荐 */
|
|
|
+.recommend-section {
|
|
|
+ background-color: #fff;
|
|
|
+ margin: 20rpx 30rpx 30rpx;
|
|
|
+ border-radius: 20rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.recommend-main {
|
|
|
+ padding: 0 30rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.recommend-large {
|
|
|
+ display: flex;
|
|
|
+ padding-bottom: 30rpx;
|
|
|
+ border-bottom: 1rpx solid #eee;
|
|
|
+}
|
|
|
+
|
|
|
+.recommend-large image {
|
|
|
+ width: 190rpx;
|
|
|
+ height: 250rpx;
|
|
|
+ border-radius: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.book-info {
|
|
|
+ flex: 1;
|
|
|
+ margin-left: 20rpx;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ justify-content: space-between;
|
|
|
+}
|
|
|
+
|
|
|
+.book-title {
|
|
|
+ font-size: 30rpx;
|
|
|
+ font-weight: bold;
|
|
|
+ margin-bottom: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.book-desc {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #666;
|
|
|
+ line-height: 1.5;
|
|
|
+ display: -webkit-box;
|
|
|
+ -webkit-line-clamp: 3;
|
|
|
+ -webkit-box-orient: vertical;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+}
|
|
|
+
|
|
|
+.book-stats {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #007aff;
|
|
|
+}
|
|
|
+
|
|
|
+.recommend-books {
|
|
|
+ display: flex;
|
|
|
+ padding: 30rpx;
|
|
|
+ justify-content: space-between;
|
|
|
+}
|
|
|
+
|
|
|
+.book-item {
|
|
|
+ width: 22%;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+}
|
|
|
+
|
|
|
+.book-item image {
|
|
|
+ width: 100%;
|
|
|
+ height: 220rpx;
|
|
|
+ border-radius: 10rpx;
|
|
|
+ margin-bottom: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.book-item text {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #333;
|
|
|
+ text-align: center;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ white-space: nowrap;
|
|
|
+ width: 100%;
|
|
|
+}
|
|
|
+
|
|
|
+/* 全网热推 */
|
|
|
+.hot-section {
|
|
|
+ background-color: #fff;
|
|
|
+ margin: 20rpx 30rpx 30rpx;
|
|
|
+ border-radius: 20rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-books {
|
|
|
+ padding: 0 30rpx 30rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-item {
|
|
|
+ display: flex;
|
|
|
+ margin-bottom: 30rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-item:last-child {
|
|
|
+ margin-bottom: 0;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-item image {
|
|
|
+ width: 200rpx;
|
|
|
+ height: 270rpx;
|
|
|
+ border-radius: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-info {
|
|
|
+ flex: 1;
|
|
|
+ margin-left: 20rpx;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ justify-content: space-between;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-title {
|
|
|
+ font-size: 30rpx;
|
|
|
+ font-weight: bold;
|
|
|
+ margin-bottom: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-desc {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #666;
|
|
|
+ line-height: 1.5;
|
|
|
+ display: -webkit-box;
|
|
|
+ -webkit-line-clamp: 3;
|
|
|
+ -webkit-box-orient: vertical;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+}
|
|
|
+
|
|
|
+.hot-book-stats {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #999;
|
|
|
+}
|
|
|
+
|
|
|
+/* 强力推荐 */
|
|
|
+.strong-recommend {
|
|
|
+ background-color: #fff;
|
|
|
+ margin: 20rpx 30rpx 30rpx;
|
|
|
+ border-radius: 20rpx;
|
|
|
+ width: 690rpx;
|
|
|
+ box-sizing: border-box;
|
|
|
+}
|
|
|
+
|
|
|
+.strong-books {
|
|
|
+ display: flex;
|
|
|
+ padding: 0 30rpx 30rpx;
|
|
|
+ justify-content: space-between;
|
|
|
+}
|
|
|
+
|
|
|
+.strong-book-item {
|
|
|
+ width: 22%;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+}
|
|
|
+
|
|
|
+.strong-book-item image {
|
|
|
+ width: 100%;
|
|
|
+ height: 220rpx;
|
|
|
+ border-radius: 10rpx;
|
|
|
+ margin-bottom: 10rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.strong-book-item text {
|
|
|
+ font-size: 24rpx;
|
|
|
+ color: #333;
|
|
|
+ text-align: center;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+ white-space: nowrap;
|
|
|
+ width: 100%;
|
|
|
+}
|
|
|
+
|
|
|
+/* 底部Tab导航 */
|
|
|
+.tab-bar {
|
|
|
+ position: fixed;
|
|
|
+ bottom: 0;
|
|
|
+ left: 0;
|
|
|
+ width: 100%;
|
|
|
+ height: 100rpx;
|
|
|
+ display: flex;
|
|
|
+ background-color: #fff;
|
|
|
+ border-top: 1rpx solid #eee;
|
|
|
+ z-index: 100;
|
|
|
+}
|
|
|
+
|
|
|
+.tab-item {
|
|
|
+ flex: 1;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: center;
|
|
|
+}
|
|
|
+
|
|
|
+.tab-item image {
|
|
|
+ width: 50rpx;
|
|
|
+ height: 50rpx;
|
|
|
+ margin-bottom: 6rpx;
|
|
|
+}
|
|
|
+
|
|
|
+.tab-item text {
|
|
|
+ font-size: 22rpx;
|
|
|
+ color: #999;
|
|
|
+}
|
|
|
+
|
|
|
+.tab-item.active text {
|
|
|
+ color: #ff5252;
|
|
|
+}
|