.challenge-container {
    max-width: 1000px;
    margin: 0 auto;
}

.challenge-header {
    background: linear-gradient(135deg, #0a2a3a 0%, #001927 100%);
    border: 2px solid #f33;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 20px rgba(255, 51, 51, 0.2);
}

.challenge-title {
    color: #f33;
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 20px 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(255, 51, 51, 0.5);
}

.challenge-dates {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    color: #ccc;
    font-size: 14px;
    flex-wrap: wrap;
    gap: 10px;
}

.challenge-dates .start-date {
    color: #4ade80;
}

.challenge-dates .end-date {
    color: #f33;
}

.progress-container {
    background: #1a3a4a;
    border-radius: 8px;
    height: 30px;
    overflow: hidden;
    position: relative;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #ffd325 0%, #f33 100%);
    border-radius: 8px;
    position: relative;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    z-index: 2;
    white-space: nowrap;
}

.stats-row {
    display: none;
}

.stat-item {
    display: none;
}

.tabs-nav {
    display: flex;
    gap: 2px;
    padding: 0;
    background: transparent;
    margin-bottom: 0;
}

.tab-link {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    padding: 12px 20px;
    background: #0a2a3a;
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    color: #8ba3b5;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    text-align: center;
    position: relative;
}

.tab-link:hover {
    color: #e8f4f8;
    background: rgba(0, 212, 255, 0.1);
    border-color: rgba(0, 212, 255, 0.3);
}

.tab-link.active {
    color: #00d4ff;
    background: linear-gradient(180deg, #0a1a2a 0%, #0a2a3a 100%);
    border-color: #00d4ff;
    border-top-width: 2px;
    border-top-color: #00d4ff;
    margin-bottom: -1px;
    padding-bottom: 13px;
}

.tab-link.active::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 10%;
    right: 10%;
    height: 2px;
    background: #00d4ff;
    box-shadow: 0 0 10px #00d4ff;
    border-radius: 0 0 2px 2px;
}

.search-container {
    background: #0a2a3a;
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-top: none;
    border-bottom: none;
    padding: 15px 20px;
}

.filter-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
    margin-top: 12px;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    color: #8ba3b5;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
    order: 1;
}

.filter-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
    appearance: none;
    background: #1b2838;
    border: 2px solid #3a4a55;
    border-radius: 4px;
    position: relative;
    transition: all 0.2s ease;
}

.filter-checkbox input[type="checkbox"]:checked {
    background: #00d4ff;
    border-color: #00d4ff;
}

.filter-checkbox input[type="checkbox"]:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #001927;
    font-size: 14px;
    font-weight: bold;
}

.filter-checkbox:hover {
    color: #e8f4f8;
}

.filter-checkbox:hover input[type="checkbox"] {
    border-color: #00d4ff;
}

.tab-panel {
    display: none;
    background: #0a2a3a;
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-top: none;
    border-radius: 0 0 12px 12px;
}

.tab-panel.active {
    display: block;
}

.search-input {
    width: 100%;
    display: block;
    border-radius: 8px;
    box-sizing: border-box;
    padding: 12px 15px;
    font-size: 14px;
    background: #1b2838;
    border: 1px solid rgba(0, 212, 255, 0.2);
    color: #e8f4f8;
    transition: all 0.2s ease;
}

.search-input:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

.search-input::placeholder {
    color: #8ba3b5;
}

.player-row {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border-bottom: 1px solid #1a3a4a;
    transition: background 0.2s;
}

.player-row:last-child {
    border-bottom: none;
}

.player-row:hover {
    background: rgba(255, 51, 51, 0.1);
}

.table-headers {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    background: transparent;
    border-bottom: 1px solid rgba(0, 212, 255, 0.15);
    font-weight: 600;
    color: #00d4ff;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-position {
    width: 50px;
    flex-shrink: 0;
}

.header-rank {
    width: 24px;
    margin-right: 10px;
    flex-shrink: 0;
}

.header-name {
    flex: 1;
}

.header-stars {
    margin-left: auto;
    padding-left: 15px;
    flex-shrink: 0;
}

.player-row.hidden {
    display: none;
}

.player-position {
    width: 50px;
    color: #666;
    font-size: 14px;
    font-weight: 600;
    flex-shrink: 0;
}

.player-position.top10 {
    color: #ffd700;
}

.player-position.top50 {
    color: #c0c0c0;
}

.player-position.top100 {
    color: #cd7f32;
}

.player-rank-icon {
    width: 24px;
    height: 24px;
    margin-right: 10px;
    flex-shrink: 0;
}

.player-rank-icon .rank-icon {
    width: 24px;
    height: 24px;
}

.player-rank-icon .rank-unknown {
    width: 24px;
    height: 24px;
    font-size: 14px;
}

.player-name-container {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.clan-tag {
    color: #4a9eff;
    margin-right: 6px;
    font-size: 14px;
    flex-shrink: 0;
    text-decoration: none;
}

.clan-tag:hover {
    color: #6ab0ff;
}

.player-nick {
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-nick.in-db {
    color: #4ade80;
}

.player-nick.in-db:hover {
    color: #6ee7a0;
    text-decoration: underline;
}

.player-nick.not-in-db {
    color: #f77;
    text-decoration: none;
}

.player-nick.not-in-db:hover {
    color: #f99;
    text-decoration: underline;
}

.player-stars {
    color: #ffd700;
    font-size: 14px;
    font-weight: 600;
    margin-left: auto;
    padding-left: 15px;
    flex-shrink: 0;
}

.no-data {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 16px;
}

.no-results {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-size: 14px;
    display: none;
}

.no-results.visible {
    display: block;
}

@media (max-width: 768px) {
    .challenge-header {
        padding: 20px 15px;
    }

    .challenge-title {
        font-size: 22px;
        letter-spacing: 1px;
    }

    .challenge-dates {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    .progress-text {
        font-size: 11px;
    }

    .tab-link {
        padding: 10px 15px;
        font-size: 12px;
    }

    .search-container {
        padding: 12px;
    }

    .search-input {
        padding: 10px 12px;
        font-size: 14px;
    }

    .table-headers {
        padding: 10px 12px;
        font-size: 11px;
    }

    .header-position {
        width: 40px;
    }

    .header-rank {
        width: 20px;
        margin-right: 8px;
    }

    .player-row {
        padding: 10px 12px;
    }

    .player-position {
        width: 40px;
        font-size: 12px;
    }

    .player-rank-icon {
        width: 20px;
        height: 20px;
        margin-right: 8px;
    }

    .player-rank-icon .rank-icon {
        width: 20px;
        height: 20px;
    }

    .player-rank-icon .rank-unknown {
        width: 20px;
        height: 20px;
        font-size: 12px;
    }

    .clan-tag {
        font-size: 12px;
    }

    .player-nick {
        font-size: 13px;
    }

    .player-stars {
        font-size: 12px;
        padding-left: 10px;
    }
}

@media (max-width: 480px) {
    .challenge-title {
        font-size: 18px;
    }

    .tab-link {
        padding: 10px 8px;
        font-size: 11px;
    }

    .search-container {
        padding: 10px;
    }

    .table-headers {
        padding: 8px 10px;
        font-size: 10px;
    }

    .header-position {
        width: 35px;
    }

    .header-rank {
        width: 20px;
        margin-right: 6px;
    }
}