/* ===================================================================
   TOP ARMAS TABLE - CSS BASEADO NO DESIGN TOPDEATHS
   Autor: MAJESTIC S+Z
   Versão: 2025 - NOVO DESIGN TEMÁTICO
   Compatível com: Counter-Strike 1.6 MOTD
   Colunas: Arma | Jogador | Kills | Headshots
   =================================================================== */

/* 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.3;
    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;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container principal - Adaptado para armas */
.container {
    max-width: 850px;
    width: 100%;
    margin: 12px auto;
    padding: 10px;
    background: rgba(15, 25, 5, 0.9); /* Fundo padrão verde escuro */
    border-radius: 8px;
    box-shadow: 0 0 25px rgba(0, 128, 0, 0.6); /* Sombra verde */
    border: 2px solid rgba(0, 128, 0, 0.8); /* Borda verde */
    position: relative;
    display: block;
    margin-bottom: 20px;
}

/* Cores específicas por categoria */
.container.RIFLES {
    background: rgba(5, 15, 25, 0.9);
    box-shadow: 0 0 25px rgba(0, 100, 200, 0.6);
    border: 2px solid rgba(0, 150, 255, 0.8);
}

.container.PISTOLAS {
    background: rgba(25, 5, 5, 0.9);
    box-shadow: 0 0 25px rgba(200, 50, 50, 0.6);
    border: 2px solid rgba(255, 100, 100, 0.8);
}

.container.SNIPERS {
    background: rgba(5, 5, 25, 0.9);
    box-shadow: 0 0 25px rgba(100, 100, 200, 0.6);
    border: 2px solid rgba(150, 150, 255, 0.8);
}

.container.SMG {
    background: rgba(15, 25, 15, 0.9);
    box-shadow: 0 0 25px rgba(50, 200, 50, 0.6);
    border: 2px solid rgba(100, 255, 100, 0.8);
}

.container.OUTRAS {
    background: rgba(25, 20, 5, 0.9);
    box-shadow: 0 0 25px rgba(200, 150, 50, 0.6);
    border: 2px solid rgba(255, 200, 100, 0.8);
}

/* Título principal */
h1 {
    text-align: center;
    font-size: 24px;
    font-weight: bold;
    color: #00FF00;
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.RIFLES h1 { color: #00BFFF; }
.PISTOLAS h1 { color: #FF6B6B; }
.SNIPERS h1 { color: #9370DB; }
.SMG h1 { color: #32CD32; }
.OUTRAS h1 { color: #FFD700; }

/* Tabela principal */
.weapons-table,
table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.7);
}

/* Larguras das colunas para layout 4 colunas (Arma | Jogador | Kills | Headshots) */
th:nth-child(1), td:nth-child(1) { width: 15%; }  /* ARMA */
th:nth-child(2), td:nth-child(2) { width: 55%; }  /* JOGADOR */
th:nth-child(3), td:nth-child(3) { width: 15%; }  /* KILLS */
th:nth-child(4), td:nth-child(4) { width: 15%; }  /* HEADSHOTS */

/* Cabeçalho da tabela */
th {
    background: linear-gradient(135deg, #228B22 0%, #32CD32 50%, #90EE90 100%);
    color: #ffffff;
    font-weight: bold;
    font-size: 12px;
    padding: 6px 8px;
    text-align: center;
    border-bottom: 1px solid #228B22;
    height: 45px;
}

/* Headers específicos por categoria */
.RIFLES th { background: linear-gradient(135deg, #1E90FF 0%, #00BFFF 50%, #87CEEB 100%); }
.PISTOLAS th { background: linear-gradient(135deg, #DC143C 0%, #FF6B6B 50%, #FFA0A0 100%); }
.SNIPERS th { background: linear-gradient(135deg, #4B0082 0%, #9370DB 50%, #DDA0DD 100%); }
.SMG th { background: linear-gradient(135deg, #228B22 0%, #32CD32 50%, #90EE90 100%); }
.OUTRAS th { background: linear-gradient(135deg, #DAA520 0%, #FFD700 50%, #FFFF99 100%); }

/* Ícones nos headers */
th:nth-child(1) {
    background-image: url('http://www.majesticsz.ihosts3.pt/ranking_map_global/imagens/icons/icon-star.png');
    background-size: 30%;
    background-repeat: no-repeat;
    background-position: center;
    text-indent: -9999px;
}

th:nth-child(2) {
    background-image: url('http://www.majesticsz.ihosts3.pt/ranking_map_global/imagens/icon-jogadores4.png');
    background-size: 65%;
    background-repeat: no-repeat;
    background-position: center;
    text-indent: -9999px;
}

th:nth-child(3) {
    background-image: url('http://www.majesticsz.ihosts3.pt/ranking_map_global/imagens/icons/icon-kills_deagle.png');
    background-size: 32%;
    background-repeat: no-repeat;
    background-position: center;
    text-indent: -9999px;
}

th:nth-child(4) {
    background-image: url('http://www.majesticsz.ihosts3.pt/ranking_map_global/imagens/icons/icon-headshot.png');
    background-size: 26%;
    background-repeat: no-repeat;
    background-position: center center;
    text-indent: -9999px;
}

th:first-child { border-top-left-radius: 8px; }
th:last-child { border-top-right-radius: 8px; }

/* Linhas da tabela */
td {
    padding: 2px 6px;
    text-align: center;
    font-size: 13px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    vertical-align: middle;
    height: 35px;
}

/* Linhas alternadas padrão */
tr.a td {
    background: rgba(20, 40, 20, 0.7);
}

tr.b td {
    background: rgba(10, 20, 10, 0.8);
}

/* Cores alternadas por categoria */
.RIFLES tr.a td { background: rgba(20, 30, 40, 0.7); }
.RIFLES tr.b td { background: rgba(10, 20, 30, 0.8); }

.PISTOLAS tr.a td { background: rgba(40, 20, 20, 0.7); }
.PISTOLAS tr.b td { background: rgba(30, 10, 10, 0.8); }

.SNIPERS tr.a td { background: rgba(20, 20, 40, 0.7); }
.SNIPERS tr.b td { background: rgba(10, 10, 30, 0.8); }

.SMG tr.a td { background: rgba(20, 40, 20, 0.7); }
.SMG tr.b td { background: rgba(10, 30, 10, 0.8); }

.OUTRAS tr.a td { background: rgba(40, 35, 20, 0.7); }
.OUTRAS tr.b td { background: rgba(30, 25, 10, 0.8); }

/* Hover nas linhas */
tr:hover td {
    background: rgba(128, 128, 128, 0.3) !important;
    transform: scale(1.01);
}

/* Weapon Icons */
.weapon {
    width: 75px;
    height: 40px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    display: inline-block;
    margin: 0 auto;
}

/* Weapon-specific backgrounds */
.weapon.ak47 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/ak47.png'); }
.weapon.m4a1 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/m4a1.png'); }
.weapon.awp { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/awp.png'); }
.weapon.deagle { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/deagle.png'); }
.weapon.glock { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/glock.png'); }
.weapon.usp { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/usp.png'); }
.weapon.p228 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/p228.png'); }
.weapon.elite { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/dualelites.png'); }
.weapon.fiveseven { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/fiveseven.png'); }
.weapon.famas { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/famas.png'); }
.weapon.galil { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/galil.png'); }
.weapon.aug { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/aug.png'); }
.weapon.sg552 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/sg552.png'); }
.weapon.scout { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/scout.png'); }
.weapon.g3sg1 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/g3sg1.png'); }
.weapon.sg550 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/sg550.png'); }
.weapon.mp5 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/mp5.png'); }
.weapon.p90 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/p90.png'); }
.weapon.ump45 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/ump45.png'); }
.weapon.mac10 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/mac10.png'); }
.weapon.tmp { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/tmp.png'); }
.weapon.xm1014 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/xm1014.png'); }
.weapon.m3 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/m3.png'); }
.weapon.m249 { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/m249.png'); }
.weapon.knife { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/knife.png'); }
.weapon.hegrenade { background-image: url('http://www.majesticsz.ihosts3.pt/top_armas_global/weapons/hegrenade.png'); }

/* Estilo das colunas */
td:nth-child(1) { /* Coluna da arma */
    font-weight: bold;
    color: #FFD700;
}

td:nth-child(2) { /* Coluna do jogador */
    font-weight: bold;
    color: #FFA500;
    text-align: center;
}

td:nth-child(3) { /* Coluna de kills */
    font-weight: bold;
    color: #00FF00;
    font-size: 14px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
    text-align: center;
}

td:nth-child(4) { /* Coluna de headshots */
    color: #FF4500;
    font-weight: bold;
    font-size: 14px;
    text-align: center !important;
}

/* Responsivo */
@media (max-width: 600px) {
    .container {
        margin: 5px;
        padding: 5px;
    }
    
    th, td {
        font-size: 11px;
        padding: 3px;
    }
    
    th {
        height: 35px;
    }
    
    .weapon {
        width: 40px;
        height: 20px;
    }
}

/* No data styling */
.no-data {
    color: #888 !important;
    font-style: italic;
}