/* Ranking Page Specific Styles */

/* Main Content */
.main-content {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 30px;
    border: 1px solid #333;
    margin-top: 20px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.ranking-container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Page Title */
.page-title {
    text-align: center;
    margin-bottom: 30px;
}

.page-title h2 {
    color: #ffffff;
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.page-title h2 i {
    color: #ff4444;
    margin-right: 10px;
}

.page-title p {
    color: #cccccc;
    font-size: 1rem;
}

/* Category Tabs */
.category-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.tab-btn {
    background: #2a2a2a;
    border: 1px solid #444;
    color: #cccccc;
    padding: 12px 24px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tab-btn:hover {
    background: #ff4444;
    color: white;
    border-color: #ff4444;
    transform: translateY(-2px);
}

.tab-btn.active {
    background: #ff4444;
    color: white;
    border-color: #ff4444;
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.4);
}

/* Filters */
.filters {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    align-items: end;
    justify-content: center;
    background: #2a2a2a;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #444;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group label {
    font-weight: bold;
    color: #cccccc;
    font-size: 14px;
}

.filter-select {
    padding: 10px 15px;
    border: 1px solid #444;
    border-radius: 5px;
    background: #1a1a1a;
    color: #ffffff;
    font-size: 14px;
    min-width: 150px;
    transition: border-color 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #ff4444;
}

.apply-btn {
    background: #ff4444;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.apply-btn:hover {
    background: #cc3333;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.4);
}

/* Loading */
.loading {
    text-align: center;
    padding: 40px;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    backdrop-filter: blur(5px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.loading.show {
    opacity: 1;
    visibility: visible;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #444;
    border-top: 4px solid #ff4444;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading p {
    color: #cccccc;
    font-size: 16px;
}

/* Ranking Table */
.ranking-table-container {
    margin-bottom: 30px;
    overflow-x: auto;
    min-height: 400px;
    contain: layout;
}

.ranking-table {
    width: 100%;
    border-collapse: collapse;
    background: #2a2a2a;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #444;
}

.ranking-table th {
    background: #ff4444;
    color: white;
    padding: 15px;
    text-align: left;
    font-weight: bold;
    font-size: 14px;
}

.ranking-table td {
    padding: 15px;
    border-bottom: 1px solid #444;
    font-size: 14px;
    color: #ffffff;
}

.ranking-table tr:hover {
    background: #333;
}

.ranking-table tr:last-child td {
    border-bottom: none;
}

/* Rank Column */
.ranking-table td:first-child {
    font-weight: 700;
    font-size: 18px;
    color: #ff4444;
    text-align: center;
    min-width: 60px;
}



/* Character Column */
.character-cell {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: bold;
}

/* Class Cell */
.class-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Class Image */
.class-image {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

/* Class Text */
.class-text {
    font-size: 14px;
    font-weight: 500;
    color: #ffffff;
}

/* School Cell */
.school-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* School Image */
.school-image {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

/* School Column */
.school-badge {
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
}

/* Status Column */
.status-badge {
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    display: inline-block;
}

.status-online {
    background: #48bb78;
    color: white;
}

.status-offline {
    background: #e53e3e;
    color: white;
}

/* Value Column */
.value-cell {
    font-weight: 700;
    color: #ff4444;
    font-size: 16px;
}

/* PK Columns */
#pk-kill-header,
#pk-death-header {
    background: #ff4444;
    color: white;
    padding: 15px;
    text-align: left;
    font-weight: bold;
    font-size: 14px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.page-btn {
    background: #ff4444;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.page-btn:hover:not(:disabled) {
    background: #cc3333;
    transform: translateY(-2px);
}

.page-btn:disabled {
    background: #666;
    cursor: not-allowed;
    transform: none;
}

.page-info {
    font-weight: bold;
    color: #cccccc;
    font-size: 14px;
}

/* Error Message */
.error-message {
    background: #2a1a1a;
    color: #ff6b6b;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid #ff4444;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.error-message i {
    font-size: 18px;
}



/* Responsive Design for Ranking Specific Elements */
@media (max-width: 768px) {
    .category-tabs {
        gap: 8px;
    }
    
    .tab-btn {
        padding: 10px 16px;
        font-size: 12px;
    }
    
    .filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-select {
        min-width: auto;
    }
    
    .ranking-table th,
    .ranking-table td {
        padding: 10px;
        font-size: 12px;
    }
    
    .class-image {
        width: 24px;
        height: 24px;
    }
    
    .pagination {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .category-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        width: 100%;
        justify-content: center;
    }
    
    .ranking-table {
        font-size: 11px;
    }
    
    .ranking-table th,
    .ranking-table td {
        padding: 8px 5px;
    }
} 