/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    background: #f5f7fa;
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.4;
}

/* 顶部导航 */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 44px;
    background: #fff;
    display: flex;
    align-items: center;
    padding: 0 16px;
    z-index: 100;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.back-btn {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.arrow-left {
    width: 10px;
    height: 10px;
    border-left: 2px solid #333;
    border-bottom: 2px solid #333;
    transform: rotate(45deg);
}

.header h1 {
    flex: 1;
    text-align: center;
    font-size: 17px;
    font-weight: 600;
}

/* 内容区域 */
.content {
    padding: 44px 0 50px;
}

/* 平台介绍 */
.platform-intro {
    margin: 6px 8px;
}

.intro-banner {
    position: relative;
    height: 160px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.intro-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.intro-text {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 16px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: #fff;
}

.intro-text h2 {
    font-size: 24px;
    margin-bottom: 8px;
}

/* 发售日历 */
.sale-calendar {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    margin: 6px 8px;
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.section-header h2 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    color: #333;
    position: relative;
    padding-left: 10px;
}

.section-header h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 14px;
    background: #ff4d4f;
    border-radius: 1.5px;
}

.more {
    color: #999;
    font-size: 14px;
}

/* 精选藏品模块 */
.event-item {
    background: #fff;
    border-radius: 10px;
    margin-bottom: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.event-content {
    display: flex;
    padding: 10px;
    align-items: center;
}

.event-image {
    width: 100px;
    height: 100px;
    border-radius: 8px;
    object-fit: cover;
    margin-right: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.event-info {
    flex: 1;
    min-width: 0;
}

.event-title {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin: 0 0 4px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.event-subtitle {
    font-size: 13px;
    color: #666;
    margin-bottom: 6px;
}

.event-price {
    display: flex;
    align-items: center;
    font-size: 13px;
    color: #999;
}

.price-value {
    color: #ff4d4f;
    font-weight: 600;
    font-size: 15px;
}

.price-time {
    margin-left: 6px;
    font-size: 12px;
    color: #999;
}

.view-btn {
    padding: 6px 14px;
    background: linear-gradient(135deg, #ff4d4f, #ff7875);
    color: #fff;
    border-radius: 16px;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s;
    font-weight: 500;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 72px;
    box-shadow: 0 2px 4px rgba(255, 77, 79, 0.2);
}

.view-btn:active {
    transform: scale(0.96);
    background: linear-gradient(135deg, #ff7875, #ff4d4f);
}

.no-data {
    text-align: center;
    padding: 32px;
    color: #999;
    font-size: 14px;
}

.more-btn {
    text-align: center;
    padding: 16px 0;
}

.view-more-btn {
    display: inline-flex;
    align-items: center;
    color: #1890ff;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
}

.view-more-btn:hover {
    color: #40a9ff;
}

.arrow-right {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-left: 4px;
    background: url('../images/arrow-right.svg') no-repeat center;
    background-size: contain;
    transition: transform 0.3s;
}

.view-more-btn:hover .arrow-right {
    transform: translateX(4px);
}

/* 设置提醒按钮 */
.set-reminder {
    padding: 4px 12px;
    background: #f5f5f5;
    border: none;
    border-radius: 4px;
    color: #666;
    font-size: 12px;
    cursor: pointer;
}

/* 签到部分 */
.checkin-section {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    border-radius: 12px;
    padding: 12px;
    margin: 6px 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.checkin-sponsor {
    color: #ff4d4f;
    font-size: 13px;
}

.checkin-box {
    margin-top: 12px;
}

.checkin-progress {
    margin-bottom: 12px;
}

.progress-bar {
    height: 6px;
    background: #f0f0f0;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 6px;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #ff4d4f, #ff7875);
    transition: width 0.3s ease;
}

.checkin-rewards {
    display: flex;
    justify-content: space-between;
    padding: 0 2px;
}

.checkin-rewards span {
    font-size: 11px;
    color: #666;
}

.checkin-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 12px;
}

.checkin-stats {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.checkin-stats span {
    font-size: 13px;
    color: #666;
}

.checkin-stats em {
    font-style: normal;
    color: #ff4d4f;
    font-weight: bold;
}

.checkin-btn {
    padding: 8px 24px;
    border: none;
    background: linear-gradient(135deg, #ff4d4f, #ff7875);
    color: white;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 2px 6px rgba(255, 77, 79, 0.2);
}

.checkin-btn:active {
    transform: scale(0.96);
    background: linear-gradient(135deg, #ff7875, #ff4d4f);
}

.checkin-btn:disabled {
    background: #d9d9d9;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

@media screen and (max-width: 768px) {
    .checkin-info {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        text-align: left;
        gap: 16px;
    }
    
    .checkin-stats {
        margin-bottom: 0;
    }
    
    .checkin-btn {
        width: auto;
        padding: 12px 32px;
    }
}

/* 文章列表 */
.articles {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    margin: 6px 8px;
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.article-item {
    display: flex;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    cursor: pointer;
}

.article-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.article-item img {
    width: 100px;
    height: 70px;
    border-radius: 6px;
    object-fit: cover;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.article-info {
    flex: 1;
    min-width: 0;
}

.article-info h3 {
    font-size: 14px;
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.article-meta {
    color: #999;
    font-size: 12px;
}

.article-meta span {
    margin-right: 10px;
}

/* 底部导航栏 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    display: flex;
    height: 55px;
    box-shadow: 0 -1px 5px rgba(0, 0, 0, 0.05);
    z-index: 100;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #999;
    font-size: 12px;
    padding: 6px 0;
}

.nav-item i {
    font-size: 18px;
    margin-bottom: 2px;
}

.nav-item span {
    font-size: 12px;
    margin-top: 2px;
}

.nav-item.active {
    color: #1677ff;
}

/* 适配刘海屏 */
@supports (padding-bottom: constant(safe-area-inset-bottom)) {
    .bottom-nav {
        padding-bottom: constant(safe-area-inset-bottom);
        height: calc(55px + constant(safe-area-inset-bottom));
    }
}

@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav {
        padding-bottom: env(safe-area-inset-bottom);
        height: calc(55px + env(safe-area-inset-bottom));
    }
}

/* Toast提示 */
.toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1000;
}

.toast.show {
    opacity: 1;
}

/* 用户信息 */
.user-info {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    padding: 8px 12px;
    display: flex;
    align-items: center;
    margin: 6px 8px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 12px;
    border: 2px solid rgba(24, 144, 255, 0.2);
    flex-shrink: 0;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-details {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.user-name-wrapper {
    display: flex;
    align-items: center;
    margin-right: auto;
}

.user-name {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
}

.points-display {
    display: flex;
    align-items: center;
    margin-left: 12px;
}

.points-label {
    font-size: 14px;
    color: #666;
    margin-right: 4px;
}

.points-value {
    font-size: 15px;
    font-weight: 600;
    color: #ff4d4f;
}

/* 适配小屏幕 */
@media screen and (max-width: 360px) {
    .user-info {
        padding: 8px 12px;
    }
    
    .user-avatar {
        width: 32px;
        height: 32px;
        margin-right: 8px;
    }
    
    .user-name {
        font-size: 14px;
        max-width: 100px;
    }
    
    .points-display {
        margin-left: 8px;
    }
    
    .points-label {
        font-size: 13px;
    }
    
    .points-value {
        font-size: 14px;
    }
}

/* 适配大屏幕 */
@media screen and (min-width: 768px) {
    .user-info {
        max-width: 600px;
        margin: 12px auto;
    }
    
    .user-name {
        max-width: 160px;
    }
}

/* 适配深色模式 */
@media (prefers-color-scheme: dark) {
    .user-info {
        background: linear-gradient(135deg, #096dd9, #1890ff);
    }
    
    .user-stats {
        background: rgba(0, 0, 0, 0.2);
    }
    
    .badge {
        background: #ff4d4f;
    }
}

/* PDF展示 */
.pdf-section {
    background: linear-gradient(135deg, #fff, #f8f9fa);
    margin: 6px 8px;
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.pdf-container {
    margin-top: 12px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.pdf-container embed {
    display: block;
    border: none;
}

@media screen and (max-width: 768px) {
    .pdf-container {
        height: 400px;
    }
    
    .pdf-container embed {
        height: 100%;
    }
}

/* 快捷入口 */
.quick-links {
    margin: 6px 8px;
}

.link-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.link-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 8px;
    background: #fff;
    border-radius: 10px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    white-space: nowrap;
}

.official-platform {
    color: #ff4d4f;
    background: #fff5f5;
    border: 1px solid #ffccc7;
}

.qr-group {
    color: #1890ff;
    background: #e6f7ff;
    border: 1px solid #91d5ff;
}

.qr-wechat {
    color: #52c41a;
    background: #f6ffed;
    border: 1px solid #b7eb8f;
}

.app-download {
    color: #722ed1;
    background: #f9f0ff;
    border: 1px solid #d3adf7;
}

/* 二维码弹窗 */
.qr-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.qr-modal.show {
    display: flex;
}

.qr-modal-content {
    background: #fff;
    border-radius: 12px;
    width: 300px;
    max-width: 90%;
    overflow: hidden;
    animation: modalShow 0.3s ease;
}

.qr-modal-header {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.qr-modal-header h3 {
    margin: 0;
    font-size: 16px;
    color: #333;
}

.close-btn {
    font-size: 24px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

.qr-modal-body {
    padding: 20px;
    text-align: center;
}

.qr-modal-body img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

@keyframes modalShow {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* PDF控制按钮样式 */
.pdf-controls button {
    margin: 0 4px;
    padding: 6px 16px;
    border: none;
    background: #FF0036 !important; /* 使用 !important 确保覆盖其他样式 */
    color: white !important;
    border-radius: 15px;
    cursor: pointer;
    font-size: 14px;
    min-width: 64px;
    transition: background-color 0.3s ease;
}

.pdf-controls button:disabled {
    background: #ccc !important;
    cursor: not-allowed;
}

.pdf-controls button:active:not(:disabled) {
    background: #E60012 !important;
}

.pdf-controls button:hover:not(:disabled) {
    background: #FF1A1A !important;
}

/* 确保缩放控制按钮也使用相同样式 */
.zoom-controls button {
    background: #FF0036 !important;
    color: white !important;
}

.zoom-controls button:disabled {
    background: #ccc !important;
}

.zoom-controls button:active:not(:disabled) {
    background: #E60012 !important;
} 