/* ===================================================================
   TOP 10 KNIFE RANKING - CSS PARA CS 1.6 MOTD (ESTILO M4A1)
   Autor: MAJESTIC S+Z
   Versão: 2024 - KNIFE EDITION
   Compatível com: Counter-Strike 1.6 MOTD
   =================================================================== */

/* Reset básico e configurações globais */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Tahoma', 'Arial', sans-serif;
    font-size: 12px;
    line-height: 1.4;
    color: #ffffff;
    background: url('http://www.majesticsz.ihosts3.pt/adp3.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-position: center center;
    background-attachment: fixed;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container principal */
.container {
    max-width: 650px;
    margin: 25px auto;
    padding: 10px;
    background: rgba(10, 5, 5, 0.9);
    border-radius: 8px;
    box-shadow: 0 0 25px rgba(192, 192, 192, 0.5);
    border: 2px solid rgba(192, 192, 192, 0.8);
    position: relative;
}

/* Título principal */
h1 {
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    color: #C0C0C0;
    margin-bottom: 12px;
    padding: 8px;
    background: linear-gradient(90deg, transparent, rgba(50, 30, 30, 0.3), transparent);
    border-radius: 4px;
}

/* Tabela principal */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 auto;
    background: rgba(30, 15, 15, 0.9);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.5);
    table-layout: fixed;
}

/* Larguras específicas das colunas */
th:nth-child(1), td:nth-child(1) { width: 8%; }  /* Posicao */
th:nth-child(2), td:nth-child(2) { width: 30%; } /* Jogador */
th:nth-child(3), td:nth-child(3) { width: 11%; } /* Kills */
th:nth-child(4), td:nth-child(4) { width: 11%; } /* Mortes */
th:nth-child(5), td:nth-child(5) { width: 13%; } /* Backstabs */
th:nth-child(6), td:nth-child(6) { width: 11%; } /* K/D */
th:nth-child(7), td:nth-child(7) { width: 16%; } /* Taxa Backstab */

/* Cabeçalho da tabela */
th {
    background: linear-gradient(135deg, #404040 0%, #606060 50%, #C0C0C0 100%);
    color: #ffffff;
    font-weight: bold;
    font-size: 11px;
    padding: 8px 4px;
    text-align: center;
    border-bottom: 1px solid #333333;
}

th:first-child {
    border-top-left-radius: 8px;
}

th:last-child {
    border-top-right-radius: 8px;
}

/* Linhas da tabela */
td {
    padding: 6px 3px;
    text-align: center;
    font-size: 11px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

/* Estilo das linhas alternadas */
tr.a {
    background: linear-gradient(90deg, rgba(50, 30, 30, 0.2), rgba(50, 30, 30, 0.1));
    border-left: 3px solid #606060;
}

tr.b {
    background: linear-gradient(90deg, rgba(60, 60, 60, 0.15), rgba(60, 60, 60, 0.08));
    border-left: 3px solid #C0C0C0;
}

/* Hover effect nas linhas */
tr:hover {
    background: linear-gradient(90deg, rgba(192, 192, 192, 0.25), rgba(192, 192, 192, 0.15)) !important;
    transform: scale(1.01);
    box-shadow: 0 2px 10px rgba(192, 192, 192, 0.4);
}

/* Coluna de posição (Posicao) */
td:first-child {
    font-weight: bold;
    font-size: 13px;
    color: #C0C0C0;
}

/* Cores alternadas para posições ímpares e pares */
tr:nth-child(odd) td:first-child { color: #C0C0C0; } /* 1º, 3º, 5º, 7º, 9º - Prata */
tr:nth-child(even) td:first-child { color: #808080; } /* 2º, 4º, 6º, 8º, 10º - Cinza */

/* Coluna do nome do jogador */
td:nth-child(2) {
    font-weight: bold;
    color: #ffffff;
    text-align: center;
    padding: 8px 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Colunas de estatísticas */
td:nth-child(3), /* Kills */
td:nth-child(4), /* Mortes */
td:nth-child(5)  /* Backstabs */
{
    font-weight: bold;
}

/* Kills - Vermelho Claro */
td:nth-child(3) {
    color: #FF6B6B;
    font-weight: bold;
}

/* Mortes - Cinza */
td:nth-child(4) {
    color: #AAAAAA;
    font-weight: bold;
}

/* Backstabs - Vermelho Intenso com Destaque */
td:nth-child(5) {
    color: #FF4444;
    font-weight: bold;
    text-shadow: 0 0 8px #FF4444;
    background: rgba(255, 68, 68, 0.1);
    border-radius: 3px;
}

/* K/D Ratio - Azul Aço */
td:nth-child(6) {
    font-weight: bold;
    color: #4ECDC4;
}

/* Taxa Backstab - Laranja */
td:nth-child(7) {
    font-weight: bold;
    color: #FF8C42;
    text-shadow: 0 0 5px #FF8C42;
}

/* Efeitos especiais para o TOP 1 */
tr:nth-child(2) {
    background: linear-gradient(90deg, rgba(50, 30, 30, 0.4), rgba(192, 192, 192, 0.2)) !important;
    border-left: 4px solid #C0C0C0 !important;
    box-shadow: 0 0 15px rgba(192, 192, 192, 0.6);
}

/* Efeito especial para backstabs altos */
td:nth-child(5):hover {
    animation: backstab-glow 1s ease-in-out infinite alternate;
}

@keyframes backstab-glow {
    0% { 
        text-shadow: 0 0 8px #FF4444;
        background: rgba(255, 68, 68, 0.1);
    }
    100% { 
        text-shadow: 0 0 15px #FF4444, 0 0 25px #FF4444;
        background: rgba(255, 68, 68, 0.2);
    }
}

/* Responsividade para CS 1.6 MOTD */
@media screen and (max-width: 700px) {
    body {
        font-size: 10px;
    }
    
    .container {
        max-width: 95%;
        margin: 3px auto;
        padding: 8px;
        border-radius: 4px;
    }
    
    h1 {
        font-size: 14px;
        margin-bottom: 8px;
        padding: 5px;
    }
    
    th, td {
        font-size: 9px;
        padding: 4px 2px;
    }
    
    td:nth-child(2) {
        padding-left: 4px;
    }
    
    table {
        border-radius: 4px;
    }
    
    /* Ajustar larguras em mobile */
    th:nth-child(1), td:nth-child(1) { width: 6%; }  /* Posicao */
    th:nth-child(2), td:nth-child(2) { width: 28%; } /* Jogador */
    th:nth-child(3), td:nth-child(3) { width: 10%; } /* Kills */
    th:nth-child(4), td:nth-child(4) { width: 10%; } /* Mortes */
    th:nth-child(5), td:nth-child(5) { width: 12%; } /* Backstabs */
    th:nth-child(6), td:nth-child(6) { width: 12%; } /* K/D */
    th:nth-child(7), td:nth-child(7) { width: 22%; } /* Taxa Backstab */
}
