/* 移动端公共样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", "微软雅黑", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    color: #1a1a1a;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 移动端视口 */
.page-container {
    max-width: 750px;
    margin: 0 auto;
    background: transparent;
    min-height: 100vh;
    padding-bottom: 60px; /* 为TabBar留出空间 */
}

/* 顶部导航栏 */
.top-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: #fff;
    border-bottom: 1px solid #eee;
    padding: 10px 15px;
}

.top-nav-title {
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    color: #333;
}

.top-nav-back {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    border: none;
    background: none;
    cursor: pointer;
    padding: 0;
    margin: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23333'%3E%3Cpath d='M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z'/%3E%3C/svg%3E");
    background-size: 24px 24px;
    background-repeat: no-repeat;
    background-position: center;
    -webkit-tap-highlight-color: transparent;
}

.top-nav-right {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
}

.top-nav-action {
    font-size: 14px;
    color: #1890FF;
    text-decoration: none;
    cursor: pointer;
    padding: 4px 8px;
    display: inline-block;
}

.top-nav-action:active {
    opacity: 0.7;
}

/* 底部TabBar */
.tabbar {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 750px;
    height: 60px;
    background-color: #fff;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.tabbar-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #999;
    font-size: 12px;
    transition: color 0.3s;
}

.tabbar-item.active {
    color: #1890FF;
}

.tabbar-icon {
    width: 24px;
    height: 24px;
    margin-bottom: 4px;
    position: relative;
}

.tabbar-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 16px;
    height: 16px;
    background-color: #FF4D4F;
    border-radius: 50%;
    border: 3px solid #fff;
    z-index: 1;
    box-shadow: 0 2px 8px rgba(255, 77, 79, 0.5), 0 0 0 2px rgba(255, 77, 79, 0.2);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.9;
    }
}

.tabbar-text {
    font-size: 12px;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 16px;
    text-align: center;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.btn-primary {
    background-color: #1890FF;
    color: #fff;
}

.btn-primary:active {
    background-color: #1565C0;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-secondary {
    background-color: #fff;
    color: #1890FF;
    border: 1px solid #1890FF;
}

/* 卡片样式 */
.card {
    background-color: #fff;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* 列表样式 */
.list-item {
    display: flex;
    align-items: center;
    padding: 15px;
    background-color: #fff;
    border-bottom: 1px solid #eee;
    text-decoration: none;
    color: #333;
}

.list-item:active {
    background-color: #f5f5f5;
}

.list-item-icon {
    width: 40px;
    height: 40px;
    margin-right: 12px;
    border-radius: 4px;
    background-color: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.list-item-content {
    flex: 1;
}

.list-item-title {
    font-size: 16px;
    color: #333;
    margin-bottom: 4px;
}

.list-item-desc {
    font-size: 12px;
    color: #999;
}

.list-item-arrow {
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ccc'%3E%3Cpath d='M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
}

/* 角标 */
.badge {
    display: inline-block;
    min-width: 18px;
    height: 18px;
    padding: 0 6px;
    background-color: #FF4D4F;
    color: #fff;
    font-size: 12px;
    line-height: 18px;
    text-align: center;
    border-radius: 9px;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.3;
}

.empty-state-text {
    font-size: 14px;
}

/* 价格样式 */
.price {
    color: #FF4D4F;
    font-weight: 600;
}

.price-old {
    color: #999;
    text-decoration: line-through;
    font-size: 12px;
    margin-left: 8px;
}

/* 加载状态 */
.loading {
    text-align: center;
    padding: 20px;
    color: #999;
}

/* 间距工具类 */
.mt-10 { margin-top: 10px; }
.mt-15 { margin-top: 15px; }
.mt-20 { margin-top: 20px; }
.mb-10 { margin-bottom: 10px; }
.mb-15 { margin-bottom: 15px; }
.mb-20 { margin-bottom: 20px; }
.p-15 { padding: 15px; }
.px-15 { padding-left: 15px; padding-right: 15px; }
.py-15 { padding-top: 15px; padding-bottom: 15px; }

/* 文本工具类 */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-primary { color: #1890FF; }
.text-danger { color: #FF4D4F; }
.text-muted { color: #999; }
.font-bold { font-weight: 600; }

