/* 首页 V2.0 样式 - 双产品入口 */

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,144C960,149,1056,139,1152,128C1248,117,1344,107,1392,101.3L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
    pointer-events: none;
}

/* LBS 推荐卡片 */
.lbs-recommendation-card {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1rem 1.5rem;
    margin: 0 auto 1.5rem;
    max-width: 600px;
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: slideDown 0.5s ease-out;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lbs-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.lbs-content {
    flex: 1;
}

.lbs-text {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}

.lbs-subtext {
    font-size: 0.9rem;
    margin: 0.25rem 0 0 0;
    opacity: 0.9;
}

/* 实时比分/倒计时卡片 */
.match-live-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.5rem;
    margin: 0 auto;
    max-width: 500px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.match-league {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.match-info {
    font-size: 0.95rem;
    margin-bottom: 1rem;
    opacity: 0.9;
    font-weight: 400;
}

.match-timer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 2rem;
    font-weight: 800;
}

#timerText {
    font-family: 'Courier New', monospace;
    letter-spacing: 0.1em;
}

.timer-label {
    font-size: 0.875rem;
    font-weight: 500;
    opacity: 0.8;
}

/* 弹幕飘屏 */
.danmu-container {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}

.danmu-item {
    position: absolute;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    white-space: nowrap;
    animation: danmuFloat 15s linear forwards;
}

@keyframes danmuFloat {
    from {
        transform: translateX(100vw);
    }
    to {
        transform: translateX(-100%);
    }
}

/* 导航与筛选 */
.league-selector {
    background: white;
    padding: 1rem 0;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 0;
    z-index: 100;
}

.league-selector::-webkit-scrollbar {
    display: none;
}

.league-btn {
    background: transparent;
    border: none;
    padding: 0.75rem 1.5rem;
    margin: 0 0.5rem;
    font-size: 1rem;
    font-weight: 500;
    color: #6c757d;
    cursor: pointer;
    border-radius: 2rem;
    transition: all 0.3s ease;
}

.league-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.league-btn:hover:not(.active) {
    background: #f8f9fa;
}

/* 模块通用样式 */
.module-viewing,
.module-moments,
.module-scout {
    padding: 2rem 0;
    background: white;
}

.module-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 0 1rem;
}

.module-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.more-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

/* 加载状态 */
.loading-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    gap: 1rem;
    color: #6c757d;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 活动卡片 */
.event-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 0 1rem 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.event-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.highlight-card {
    border: 2px solid #667eea;
}

.event-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    z-index: 10;
}

.event-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-info {
    padding: 1.25rem;
}

.event-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 0.75rem 0;
}

.event-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
    background: #e9ecef;
    color: #6c757d;
}

.ai-tag {
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    color: #667eea;
    border: 1px solid #667eea30;
}

.event-status {
    margin-bottom: 1rem;
}

.progress-bar {
    background: #e9ecef;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    background: linear-gradient(90deg, #28a745 0%, #20c997 100%);
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
}

.event-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
    color: #6c757d;
}

.seats-left {
    color: #dc3545;
    font-weight: 600;
}

/* 头像堆叠 */
.event-avatars {
    display: flex;
    margin-top: 0.75rem;
}

.avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid white;
    margin-left: -10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
}

.avatar:first-child {
    margin-left: 0;
}

/* 热门活动行 */
.hot-events-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* PC端3列布局，每列约32% (包含gap) */
    gap: 1rem;
    padding: 0 1rem;
}

.hot-events-row .event-card {
    margin: 0;
}

.hot-events-row .event-image {
    height: 120px;
}

.hot-events-row .event-title {
    font-size: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 昨夜现场 */
.moments-marquee {
    overflow: hidden;
    padding: 0 1rem;
}

.moments-track {
    display: flex;
    gap: 1rem;
    animation: scrollLeft 30s linear infinite;
}

@keyframes scrollLeft {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

.moments-track:hover {
    animation-play-state: paused;
}

.moment-item {
    flex-shrink: 0;
    width: 200px;
    border-radius: 1rem;
    overflow: hidden;
    position: relative;
}

.moment-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.moment-location {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    padding: 1rem 0.75rem 0.75rem;
    font-size: 0.75rem;
}

/* AI 星探榜单 */
.player-list {
    list-style: none;
    padding: 0 1rem;
    margin: 0;
}

.player-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 0.75rem;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.player-item:hover {
    background: #e9ecef;
    transform: translateX(4px);
}

.player-rank {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
}

.player-item:nth-child(1) .player-rank {
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    color: #856404;
}

.player-item:nth-child(2) .player-rank {
    background: linear-gradient(135deg, #c0c0c0 0%, #e8e8e8 100%);
    color: #495057;
}

.player-item:nth-child(3) .player-rank {
    background: linear-gradient(135deg, #cd7f32 0%, #e8a872 100%);
    color: white;
}

.player-item:nth-child(n+4) .player-rank {
    background: #e9ecef;
    color: #6c757d;
}

.player-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.player-detail {
    flex: 1;
    min-width: 0;
}

.player-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.player-comment {
    font-size: 0.875rem;
    color: #6c757d;
    font-style: italic;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-score {
    font-size: 1.5rem;
    font-weight: 700;
    color: #667eea;
    flex-shrink: 0;
}

/* PK 入口 */
.pk-entry {
    text-align: center;
    padding: 2rem 1rem;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    margin: 1rem;
    border-radius: 1rem;
}

.pk-entry p {
    font-size: 1rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.btn-pk {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.75rem 2rem;
    border-radius: 2rem;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-pk:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

/* 底部悬浮按钮组 */
.fab-container {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1rem;
    z-index: 1000;
}

.fab-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.fab-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.fab-secondary {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.fab-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

.fab-icon {
    font-size: 1.25rem;
}

/* 底部 */
.footer {
    background: #2c3e50;
    color: white;
    padding: 2rem 0;
    text-align: center;
    margin-top: 2rem;
}

.footer p {
    margin: 0;
    opacity: 0.8;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hero-section {
        padding: 1.5rem 0;
    }

    .lbs-recommendation-card {
        margin: 0 1rem 1rem;
    }

    .match-live-card {
        margin: 0 1rem;
    }

    .match-timer {
        font-size: 1.5rem;
    }

    /* 移动端热门活动改为1列 */
    .hot-events-row {
        grid-template-columns: 1fr;
    }

    .fab-container {
        bottom: 1rem;
        flex-direction: column;
        gap: 0.5rem;
    }

    .fab-btn {
        width: calc(100vw - 2rem);
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .lbs-text {
        font-size: 1rem;
    }

    .lbs-subtext {
        font-size: 0.8rem;
    }

    .match-league {
        font-size: 1.1rem;
    }

    .match-timer {
        font-size: 1.25rem;
    }

    .module-header h3 {
        font-size: 1.1rem;
    }

    .player-score {
        font-size: 1.25rem;
    }
}

/* 隐藏类 */
.d-none {
    display: none !important;
}
