/* ============================================
   爆款市场紧凑优化样式
   猫哥优化 | 2026-01-20
   ============================================ */

/* 热门市场容器 - 减小padding */
.featured-markets {
    background: var(--dark-light);
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    margin-bottom: 1.5rem;
}

/* 标题 - 减小margin */
.featured-markets h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    color: var(--warning);
    font-size: 1rem;
}

/* 爆款市场网格 - 减小gap，使用4列布局 */
.featured-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

/* 大屏幕：3列 */
@media (max-width: 1600px) {
    .featured-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* 中等屏幕：2列 */
@media (max-width: 1200px) {
    .featured-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 小屏幕：1列 */
@media (max-width: 768px) {
    .featured-grid {
        grid-template-columns: 1fr;
    }
}

/* 爆款市场卡片 - 更紧凑的padding */
.featured-compact {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.featured-compact:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
    border-color: var(--primary);
}

/* 卡片顶部条纹效果 - 减小高度 */
.featured-compact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    z-index: 1;
}

/* 紧凑型头部 - 减小padding */
.featured-compact .compact-header {
    padding: 0.625rem 0.875rem 0.375rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 分类标签 - 更小的尺寸 */
.featured-compact .category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    font-size: 0.6875rem;
    font-weight: 600;
    white-space: nowrap;
}

.featured-compact .category-badge i {
    font-size: 0.75rem;
}

/* HOT标签 - 更小 */
.featured-compact .hot-badge {
    padding: 0.2rem 0.4rem;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border-radius: 4px;
    font-size: 0.5625rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    animation: pulse 2s infinite;
}

.featured-compact .hot-badge i {
    font-size: 0.625rem;
}

/* 标题 - 更紧凑 */
.featured-compact .compact-title {
    padding: 0.375rem 0.875rem 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    min-height: 2.4em;
}

/* 统计数据 - 更紧凑 */
.featured-compact .compact-stats {
    padding: 0 0.875rem;
    margin-bottom: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.featured-compact .stat-group {
    display: flex;
    gap: 0.75rem;
}

.featured-compact .stat-mini {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.featured-compact .stat-mini i {
    font-size: 0.75rem;
    opacity: 0.7;
}

.featured-compact .stat-mini span {
    font-weight: 600;
    color: var(--text);
}

/* APY标签 - 更小 */
.featured-compact .apy-badge {
    padding: 0.2rem 0.5rem;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(16, 185, 129, 0.15));
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 6px;
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--success);
}

/* 赔率显示 - 更紧凑 */
.featured-compact .compact-odds {
    padding: 0 0.875rem;
    margin-bottom: 0.625rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.featured-compact .odds-mini {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.4rem 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    font-size: 0.75rem;
}

.featured-compact .odds-mini .odds-label {
    font-weight: 600;
    margin-bottom: 0.2rem;
    font-size: 0.6875rem;
}

.featured-compact .odds-mini .odds-value {
    font-weight: 700;
    font-size: 0.875rem;
    color: var(--text);
}

.featured-compact .odds-mini .odds-percent {
    font-size: 0.625rem;
    color: var(--text-muted);
    margin-top: 0.1rem;
}

/* YES赔率 */
.featured-compact .odds-mini:first-child {
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.featured-compact .odds-mini:first-child .odds-label {
    color: var(--success);
}

/* NO赔率 */
.featured-compact .odds-mini:last-child {
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.featured-compact .odds-mini:last-child .odds-label {
    color: var(--danger);
}

/* 参与者头像 - 更紧凑 */
.featured-compact .participants-avatars {
    padding: 0 0.875rem;
    margin-bottom: 0.625rem;
}

.featured-compact .avatars-stack {
    display: flex;
    align-items: center;
    position: relative;
    height: 28px;
}

.featured-compact .avatar-item {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--dark-lighter);
    position: relative;
    overflow: hidden;
    margin-right: -8px;
}

.featured-compact .avatar-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-compact .avatar-more {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary);
    border: 2px solid var(--dark-lighter);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.625rem;
    font-weight: 700;
    color: white;
}

/* 卡片底部 - 更紧凑 */
.featured-compact .compact-footer {
    padding: 0.625rem 0.875rem;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* 创建者信息 - 更紧凑 */
.featured-compact .creator-mini {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.featured-compact .creator-avatar-wrapper {
    position: relative;
    width: 24px;
    height: 24px;
}

.featured-compact .creator-avatar-wrapper img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--border);
}

.featured-compact .creator-badge {
    position: absolute;
    bottom: -2px;
    right: -2px;
    font-size: 0.5rem;
    background: var(--dark-lighter);
    border-radius: 50%;
    width: 12px;
    height: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.featured-compact .creator-name {
    font-size: 0.7rem;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.featured-compact .creator-label {
    font-size: 0.625rem;
    opacity: 0.7;
}

/* 时间信息 - 更小 */
.featured-compact .time-mini {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.6875rem;
    color: var(--text-muted);
}

.featured-compact .time-mini i {
    font-size: 0.625rem;
}

/* 接盘标签 - 调整位置 */
.featured-compact .transfer-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.25rem 0.5rem;
    background: linear-gradient(135deg, #ec4899, #d946ef);
    color: white;
    border-radius: 6px;
    font-size: 0.625rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    z-index: 2;
    cursor: pointer;
    transition: all 0.3s;
}

.featured-compact .transfer-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
}

.featured-compact .transfer-badge i {
    font-size: 0.625rem;
}

/* 封面图样式调整 */
.featured-compact .market-cover {
    height: 100px;
    border-radius: 12px 12px 0 0;
}

/* 优化整体高度 */
.featured-compact {
    min-height: 320px;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .featured-markets {
        padding: 0.875rem;
    }
    
    .featured-compact .compact-title {
        font-size: 0.8125rem;
    }
    
    .featured-compact .stat-mini {
        font-size: 0.6875rem;
    }
}

/* 脉冲动画 */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}
