body {
            background: #121212;
            color: #e0e0e0;
            font-family: 'Segoe UI', Arial, sans-serif;
            margin: 0;
            padding: 0 0 32px 0;
        }

        table {
            border-collapse: collapse;
            width: 90%;
            max-width: 600px;
            margin: 24px auto;
            background: #181818;
            box-shadow: none;
            border-radius: 0;
            font-size: 1rem;
            overflow-x: auto;
        }

        th, td {
    padding: 10px 22px; /* Aumenta o espaçamento horizontal */
    text-align: center;
    border-bottom: 1px solid #232323;
    background: none;
    transition: none;
    font-size: 1rem;
}

        th {
            background: none;
            color: #e0e0e0;
            font-weight: 600;
            border-bottom: 2px solid #444;
            letter-spacing: 0.02em;
        }

        tr:nth-child(even) {
            background: #161616;
        }

        tr:nth-child(odd) {
            background: #181818;
        }

        /* Hover effect */
        tr.highlight-row > td {
            background: rgba(74, 144, 226, 0.1) !important;
        }

        .highlight-col {
            background: rgba(74, 144, 226, 0.1) !important;
        }

        .highlight-header {
            background: rgba(74, 144, 226, 0.2) !important;
        }

        /* Mantém o hover original para linhas não selecionadas */
        tr:not(.selected):hover > td:not(.selected) {
            background: #232323;
        }

        tr:hover {
            background: #232323;
        }

        td:first-child {
            background: none;
            color: #ffcc00;
            font-weight: 600;
            border-right: none;
            text-align: left;
        }
        
        /* Células não selecionadas em cinza */
        td:not(.selected) {
            color: #888888;
        }
        
        /* Células selecionadas em branco */
        td.selected {
            color: #ffffff;
        }

        h1 {
            font-size: 1.2rem;
            font-weight: 600;
            color: #e0e0e0;
            margin-top: 24px;
            margin-bottom: 8px;
            letter-spacing: 0.01em;
        }

        /* Header and Controls */
        .table-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 24px;
            margin: 24px auto 16px;
            padding: 0 16px;
            max-width: 1200px;
            position: relative;
        }

        .header-content {
            flex: 1;
        }

        .table-header h1 {
            margin: 0 0 12px 0;
            font-size: 1.2rem;
            font-weight: 600;
            color: #e0e0e0;
            letter-spacing: 0.01em;
        }

        .controls {
            display: flex;
            gap: 12px;
            margin-top: 12px;
        }

        .selection-info {
            display: flex;
            align-items: center;
            gap: 20px;
            background: rgba(40, 40, 40, 0.8);
            padding: 10px 16px;
            border-radius: 6px;
            border: 1px solid #444;
            margin-top: 12px;
            position: relative;
        }

        .selection-item {
            display: flex;
            align-items: center;
            gap: 6px;
            font-size: 14px;
        }

        .selection-item .label {
            color: #aaa;
            font-weight: 500;
        }

        #copyBtn {
            background: transparent;
            border: 1px solid #444;
            color: #888;
            width: 32px;
            height: 32px;
            border-radius: 4px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
        }

        #copyBtn:hover {
            color: #fff;
            border-color: #666;
            background: rgba(255,255,255,0.05);
        }

        .divider {
            width: 1px;
            height: 56px;
            background: #444;
            margin: 0 10px;
        }

        .logo {
            height: 56px;
            width: auto;
            display: block;
            border-radius: 4px;
        }

        /* Tooltip */
        .tooltip {
            position: absolute;
            background: rgba(0, 0, 0, 0.8);
            color: #fff;
            padding: 6px 10px;
            border-radius: 4px;
            font-size: 13px;
            pointer-events: none;
            z-index: 1000;
            opacity: 0;
            transition: opacity 0.2s;
            white-space: nowrap;
        }

        /* Table container */
        .table-container {
            text-align: center;
            font-size: 12px;
            color: #888;
            margin-top: 32px;
            border-top: 1px solid #232323;
        }

        /* Footer styles */
        footer {
            text-align: center;
            font-size: 12px;
            color: #888;
            margin-top: 32px;
            border-top: 1px solid #232323;
            padding-top: 12px;
        }

        /* Title style */
        h1 {
            text-align: center;
            font-size: medium;
        }
        /* Highlight clicked row and column */
.highlight-click {
    background-color: #27313f !important;
}

/* Selected cells */
td.selected {
    position: relative;
    z-index: 10;
    background: #2a4b8d !important;
    color: #fff !important;
    font-weight: bold;
    box-shadow: 0 0 0 2px #4a90e2;
}

/* Garante que células selecionadas tenham prioridade */

@media (max-width: 600px) {
    body {
        padding: 0;
    }
    .table-header {
        padding: 10px 0 0 0;
    }
    table {
        width: 100vw;
        min-width: 500px;
        font-size: 0.85rem;
        margin: 8px 0;
    }
    th, td {
        padding: 6px 6px;
        font-size: 0.85rem;
    }
    .selection-info {
        flex-direction: column;
        align-items: flex-start;
        width: 100vw;
        gap: 2px;
    }
    .selection-item {
        width: 100%;
        margin-bottom: 2px;
    }
    .divider, .logo {
        display: none;
    }
    .table-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .selection-info button {
        margin-top: 8px;
        width: 100%;
    }
    footer {
        font-size: 0.8rem;
    }
    .tooltip {
        font-size: 0.8rem !important;
        max-width: 90vw;
        word-break: break-all;
    }
    .header-content h1 {
        font-size: 1.1rem;
    }
}

td.selected, 
tr.highlight-row > td.selected,
.highlight-col.selected {
    background: #2a4b8d !important;
    color: #fff !important;
    position: relative;
    z-index: 5;
}

/* Estilo para células selecionadas com hover */
tr.highlight-row > td.selected,
.highlight-col.selected {
    background: #3a5b9d !important;
    box-shadow: 0 0 0 2px #5aa0ff;
}

/* Mantém o destaque da linha/coluna quando uma célula está selecionada */
tr.has-selected > td:not(.selected) {
    background: rgba(74, 144, 226, 0.1) !important;
}

.has-selected-col:not(.selected) {
    background: rgba(74, 144, 226, 0.1) !important;
}

/* Hover cruzado mais visível */
tr:hover > td:not(.selected) {
    background: rgba(100, 170, 255, 0.1) !important;
}

.highlight-col:not(.selected) {
    background: rgba(100, 170, 255, 0.1) !important;
}

td.selected:first-child {
    background: #1a3a6a !important;
    color: #ffcc00 !important;
}



/* Tooltip */
.tooltip {
    position: fixed;
    background: rgba(0, 0, 0, 0.9);
    color: #fff;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 13px;
    pointer-events: none;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.2s;
    white-space: nowrap;
    font-family: 'Segoe UI', Arial, sans-serif;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

    /* Bold first column */
        td:first-child {
            background-color: #121212; /* Cor diferente para a primeira coluna */
            font-weight: bold;
        }

        /* Sticky header */
        thead th {
            position: sticky;
            top: 0;
            background-color: #121212; /* Cor diferente para a primeira coluna */
            z-index: 2;
        }

        /* NOVO: Congela a fileira do Z positivo no topo ao rolar */
        tr.sticky-z-positive th, tr.sticky-z-positive td {
            position: sticky;
            top: 0; /* Agora sobrepõe a fileira do Z negativo */
            background-color: #121212;
            z-index: 3; /* Maior que o thead */
        }

        /* logotipo*/
        .logo {
            margin-top: 20px;
            text-align: center;
            /* Ajuste conforme necessário */
        }

        .logo-image {
            width: 240px;
            height: 93px;
            transition: transform 0.3s ease-in-out; /* Transição suave */
}

        .logo-image:hover {
            transform: scale(1.05); /* Aumenta em 10% o tamanho ao passar o cursor */
        }

        /* Highlight column header and first row */
        .highlight-header {
            color: #ffcc00 !important;
            background-color: #27313f !important;
        }

        /* Highlight full row and column */
        .highlight-full-row {
            background-color: #27313f !important;
        }

        .highlight-full-col {
            background-color: #27313f !important;
        }

        /* Garante que a célula selecionada fique destacada mesmo com hover */
td.highlight-click,
td.highlight-click:hover {
    background: #27313f !important;
    color: #ffffff !important;
}

/* Hover padrão para qualquer célula não selecionada */
td:hover:not(.highlight-click) {
    background: #232323;
    cursor: pointer;
}

/* Estado normal da célula selecionada */
td.highlight-click {
    background: #27313f !important;
    color: #ffcc00 !important;
    font-weight: bold;
    transition: background 0.2s, color 0.2s;
}

/* Hover ESPECIAL apenas para a célula selecionada */
td.highlight-click:hover {
    background: #3a2e1a !important;
    color: #ffd700 !important;
    box-shadow: 0 0 0 2px #ffcc00 inset;
    font-weight: bold;
}