/* 首页样式 - 黑金主题 */ page { background: linear-gradient(180deg, #000000 0%, #0A0A0A 100%); min-height: 100vh; } /* 容器 */ .container { padding: 30rpx; padding-bottom: 120rpx; } /* 用户信息卡片 */ .user-card { background: linear-gradient(135deg, #1A1A1A 0%, #252525 100%); border-radius: 20rpx; padding: 32rpx 24rpx; margin-bottom: 30rpx; box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.8); border: 1rpx solid rgba(212, 175, 55, 0.3); position: relative; overflow: hidden; } /* 金色顶部装饰 */ .user-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3rpx; background: linear-gradient(90deg, transparent 0%, #D4AF37 20%, #F4E6C3 50%, #D4AF37 80%, transparent 100%); background-size: 200% 100%; animation: shimmer 4s linear infinite; } @keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } } /* 用户头部 */ .user-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24rpx; } .user-basic { display: flex; align-items: center; flex: 1; } .user-avatar { width: 120rpx; height: 120rpx; border-radius: 50%; margin-right: 16rpx; background: linear-gradient(135deg, #2A2A2A 0%, #3A3A3A 100%); border: 3rpx solid #D4AF37; box-shadow: 0 4rpx 12rpx rgba(212, 175, 55, 0.4); position: relative; animation: avatarGlow 3s ease-in-out infinite; } @keyframes avatarGlow { 0%, 100% { box-shadow: 0 4rpx 12rpx rgba(212, 175, 55, 0.4); } 50% { box-shadow: 0 4rpx 20rpx rgba(212, 175, 55, 0.6), 0 0 30rpx rgba(212, 175, 55, 0.3); } } .user-info { display: flex; flex-direction: column; gap: 4rpx; } .user-nickname { font-size: 32rpx; font-weight: bold; color: #FFFFFF; } .login-tip { font-size: 24rpx; color: #B0B0B0; } /* 扫码按钮 */ .scan-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16rpx 24rpx; background: #6d552a; border-radius: 12rpx; gap: 4rpx; box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.3); } .scan-icon { font-size: 36rpx; } .scan-text { font-size: 20rpx; color: #FFFFFF; font-weight: 500; } /* 统计数据行 */ .user-stats { display: flex; align-items: center; justify-content: space-around; padding-top: 24rpx; border-top: 1rpx solid #f0f0f0; } .stat-item { display: flex; flex-direction: column; align-items: center; gap: 8rpx; } .stat-label { font-size: 24rpx; color: #B0B0B0; } .stat-value { font-size: 32rpx; font-weight: bold; color: #FFFFFF; } .stat-divider { width: 1rpx; height: 40rpx; background: #e5e5e5; } /* 操作按钮 */ .action-buttons { display: flex; gap: 20rpx; margin-bottom: 30rpx; } .action-btn { flex: 1; height: 100rpx; border-radius: 16rpx; display: flex; align-items: center; justify-content: center; gap: 12rpx; box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.08); transition: all 0.3s ease; } .action-btn:active { transform: scale(0.98); box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1); } .primary-btn { background: linear-gradient(135deg, #50C878 0%, #06a854 100%); box-shadow: 0 8rpx 24rpx rgba(80, 200, 120, 0.4); } .primary-btn:active { box-shadow: 0 4rpx 16rpx rgba(80, 200, 120, 0.5); } .secondary-btn { background: linear-gradient(135deg, #C0C0C0 0%, #E5E5E5 100%); box-shadow: 0 8rpx 24rpx rgba(192, 192, 192, 0.3); } .secondary-btn:active { box-shadow: 0 4rpx 16rpx rgba(192, 192, 192, 0.4); } .btn-icon { font-size: 40rpx; font-weight: bold; color: #FFFFFF; } .btn-text { font-size: 28rpx; font-weight: 500; color: #FFFFFF; } /* 房间区域 */ .section { margin-bottom: 30rpx; } .section-header { margin-bottom: 20rpx; padding: 0 8rpx; } .section-title { font-size: 32rpx; font-weight: bold; color: #FFFFFF; } /* 房间网格 - 一行两个 */ .room-grid { display: flex; flex-wrap: wrap; gap: 20rpx; } .room-card { flex: 0 0 calc((100% - 100rpx) / 2); background: #1A1A1A; border-radius: 20rpx; padding: 24rpx 20rpx; box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.15); transition: all 0.3s ease; display: flex; flex-direction: column; gap: 12rpx; } .room-card:active { transform: scale(0.98); box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.2); } /* 房间标题行 */ .room-title-row { display: flex; justify-content: space-between; align-items: center; } .room-name { font-size: 28rpx; font-weight: bold; color: #FFFFFF; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; margin-right: 8rpx; } .host-badge { font-size: 20rpx; padding: 4rpx 12rpx; border-radius: 6rpx; background: rgba(255, 154, 118, 0.1); color: #ff9a76; white-space: nowrap; font-weight: 500; } /* 状态和人数行 */ .room-info-row { display: flex; justify-content: space-between; align-items: center; } .room-status-badge { font-size: 20rpx; padding: 4rpx 12rpx; border-radius: 6rpx; font-weight: 500; } .room-status-badge.status-playing { background: rgba(7, 193, 96, 0.1); color: #50C878; } .room-status-badge.status-waiting { background: rgba(255, 149, 0, 0.1); color: #ff9500; } .room-players { font-size: 24rpx; color: #B0B0B0; font-weight: 500; } /* 时间行 */ .room-time { padding-top: 8rpx; border-top: 1rpx solid #f5f5f5; } .time-text { font-size: 22rpx; color: #B0B0B0; } /* 空状态 */ .empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 80rpx 0; background: #1A1A1A; border-radius: 20rpx; box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.15); margin-bottom: 20rpx; } .empty-icon { font-size: 80rpx; margin-bottom: 20rpx; opacity: 0.5; } .empty-text { font-size: 28rpx; color: #B0B0B0; margin-bottom: 12rpx; } .empty-hint { font-size: 24rpx; color: #ccc; }