| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247 |
- <template>
- <view class="home-page">
- <!-- 顶部背景与搜索区域 @Author: Antigravity -->
- <view class="header-section">
- <image src="/static/images/index-header.png" class="header-bg" mode="widthFix"></image>
- </view>
- <!-- 系统通知栏 @Author: Antigravity -->
- <view class="notice-section">
- <view class="notice-bar">
- <image src="/static/images/index-notice.png" class="notice-icon" mode="aspectFit"></image>
- <text class="notice-text">【重要通知】尊敬的用户,由于近期接送需求激增,请各位宠主尽量提前24小时进行服务预约,感谢您的理解与配合!</text>
- </view>
- </view>
- <!-- 业务导航区 (左1右2) @Author: Antigravity -->
- <view class="main-nav-section">
- <view class="nav-container">
- <!-- 左侧大按钮: 宠物接送 -->
- <view class="nav-card large-card">
- <image src="/static/images/pickup-dropoff.png" class="card-bg" mode="aspectFill"></image>
- <view class="card-info">
- <text class="card-title">宠物接送</text>
- <text class="card-desc">支持单操/往返服务</text>
- </view>
- </view>
- <!-- 右侧分栏 -->
- <view class="right-stack">
- <!-- 右上: 上门喂遛 -->
- <view class="nav-card small-card">
- <image src="/static/images/feed-walk.png" class="card-bg" mode="aspectFill"></image>
- <view class="card-info">
- <text class="card-title">上门喂遛</text>
- <text class="card-desc">每次上门基础费用</text>
- </view>
- </view>
-
- <!-- 右下: 上门洗护 -->
- <view class="nav-card small-card">
- <image src="/static/images/laundry-clean.png" class="card-bg" mode="aspectFill"></image>
- <view class="card-info">
- <text class="card-title">上门洗护</text>
- <text class="card-desc">每次上门基础费用</text>
- </view>
- </view>
- </view>
- </view>
- </view>
- <!-- 中间横幅图片 @Author: Antigravity -->
- <view class="middle-section">
- <image src="/static/images/index-middle.png" class="middle-image" mode="widthFix"></image>
- </view>
- <!-- 底部居中标志 @Author: Antigravity -->
- <view class="symbol-section">
- <image src="/static/images/index-symbol.png" class="symbol-img" mode="widthFix"></image>
- </view>
- <!-- 底部手势与文字 @Author: Antigravity -->
- <view class="hand-section">
- <view class="hand-wrapper">
- <image src="/static/images/index-hand.png" class="hand-img" mode="widthFix"></image>
- <view class="hand-text-content">
- <text class="hand-title">好萌友提醒您~</text>
- <text class="hand-subtitle">功能优化中,敬请期待~</text>
- </view>
- </view>
- </view>
- <custom-tabbar></custom-tabbar>
- </view>
- </template>
- <script setup>
- import customTabbar from '@/components/custom-tabbar/index.vue'
- /** 首页脚本 @Author: Antigravity */
- </script>
- <style lang="scss" scoped>
- .home-page {
- background: #f8f9fb;
- min-height: 100vh;
- padding-bottom: 120rpx;
- }
- /* ====== 顶部搜索与背景 ====== */
- .header-section {
- position: relative;
- width: 100%;
- }
- .header-bg {
- width: 100%;
- display: block;
- }
- /* ====== 通知栏 ====== */
- .notice-section {
- padding: 20rpx 32rpx;
- }
- .notice-bar {
- display: flex;
- align-items: center;
- background: #fffbef;
- border-radius: 20rpx;
- padding: 16rpx 24rpx;
- gap: 16rpx;
- }
- .notice-icon {
- width: 40rpx;
- height: 40rpx;
- flex-shrink: 0;
- }
- .notice-text {
- font-size: 24rpx;
- color: #e6a23c;
- line-height: 1.4;
- }
- /* ====== 核心卡片布局 @Author: Antigravity ====== */
- .main-nav-section {
- padding: 10rpx 32rpx;
- }
- .nav-container {
- display: flex;
- height: 280rpx; /* 将之前较高的 380rpx 调低,使整体按钮高度变矮 */
- gap: 20rpx;
- }
- .nav-card {
- border-radius: 24rpx;
- position: relative;
- overflow: hidden;
- background: #fff;
- }
- .card-bg {
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- z-index: 1;
- }
- .card-info {
- position: relative;
- z-index: 2;
- padding: 30rpx 24rpx;
- }
- .large-card {
- flex: 1;
- }
- .right-stack {
- flex: 1;
- display: flex;
- flex-direction: column;
- gap: 20rpx;
- }
- .small-card {
- flex: 1;
- }
- .card-title {
- font-size: 32rpx;
- font-weight: 800;
- color: #333;
- margin-bottom: 4rpx;
- display: block;
- }
- /* 根据图片色系微调文字颜色以匹配 UI 稿 */
- .large-card .card-title { color: #d35400; }
- .right-stack .small-card:first-child .card-title { color: #2c5ba7; }
- .right-stack .small-card:last-child .card-title { color: #c0392b; }
- .card-desc {
- font-size: 20rpx;
- color: #8e8e8e;
- display: block;
- }
- /* ====== 中间横幅 @Author: Antigravity ====== */
- .middle-section {
- padding: 10rpx 0; /* 缩小自身上下间距 */
- display: flex;
- justify-content: center;
- }
- .middle-image {
- width: 65%; /* 进一步缩小宽度到 65% */
- border-radius: 20rpx;
- display: block;
- }
- /* ====== 底部标志 @Author: Antigravity ====== */
- .symbol-section {
- display: flex;
- justify-content: center;
- align-items: center;
- padding: 10rpx 32rpx 20rpx; /* 控制绿色横幅的 padding 以对齐上方 */
- }
- .symbol-img {
- width: 100%; /* 中间的标志(绿色大横幅)完美等宽于三个按钮 */
- border-radius: 20rpx;
- display: block;
- }
- /* ====== 底部手势与文字 @Author: Antigravity ====== */
- .hand-section {
- padding: 30rpx 32rpx 60rpx;
- display: flex;
- justify-content: center;
- }
- .hand-wrapper {
- position: relative;
- width: 100%;
- display: flex;
- justify-content: center;
- align-items: center;
- }
- .hand-img {
- width: 100%;
- display: block;
- }
- .hand-text-content {
- position: absolute;
- top: 50%;
- left: 50%;
- transform: translate(-50%, -50%);
- display: flex;
- flex-direction: column;
- align-items: center;
- gap: 12rpx;
- }
- .hand-title {
- font-size: 28rpx;
- color: #333;
- font-weight: bold;
- }
- .hand-subtitle {
- font-size: 24rpx;
- color: #999;
- }
- </style>
|