/* Estilos para os shortcodes do Wallet */

/* Total */
.wallet-total {
    background: #333;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    text-align: center;
    margin: 20px 0;
    color: #fff;
}

.wallet-total h3 {
    margin: 0 0 15px 0;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.total-value {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    font-family: monospace;
    transition: all 0.3s ease;
}

/* Filtro */
.wallet-filter {
    display: flex;
    margin: 20px 0;
    background: #333;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    color: #fff;
}

.filter-form {
    display: flex;
    gap: 10px;
    align-items: center;
    width: 100%;
}

.wallet-filter select {
    padding: 8px 12px;
    border: 1px solid #555;
    border-radius: 4px;
   
    font-size: 14px;
    background: #444;
    color: #fff;
}

.wallet-filter select:focus {
    outline: none;
    border-color: #4169e1;
    box-shadow: 0 0 0 1px #4169e1;
}

#wallet-filter-apply {
    padding: 8px 20px;
    background: #4169e1;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.2s;
}

#wallet-filter-apply:hover:not(:disabled) {
    background: #3158d0;
}

#wallet-filter-apply:disabled {
    background: #555;
    cursor: not-allowed;
}

/* Tabela */
.wallet-table-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
    background: #333;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.wallet-front-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 750px;
    margin: 0;
}

.wallet-front-table th,
.wallet-front-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    white-space: nowrap;
}

.wallet-front-table th {
    background: rgba(0, 0, 0, 0.2);
    font-weight: 600;
    color: #fff;
}

.wallet-front-table td {
    color: #fff;
}

.wallet-front-table td:nth-child(3),
.wallet-front-table td:nth-child(4),
.wallet-front-table td:nth-child(5),
.wallet-front-table td:nth-child(6) {
    font-family: monospace;
    transition: all 0.3s ease;
}

.wallet-front-table tr:last-child td {
    border-bottom: none;
}

.wallet-front-table tr:hover td {
    background: rgba(0, 0, 0, 0.2);
}

.wallet-front-table td.no-data {
    text-align: center;
    color: #fff;
    padding: 30px 15px;
    font-style: italic;
}

.wallet-front-table td:nth-child(4),
.wallet-front-table td:nth-child(5),
.wallet-front-table td:nth-child(6),
.wallet-front-table td:nth-child(7),
.wallet-front-table th:nth-child(4),
.wallet-front-table th:nth-child(5),
.wallet-front-table th:nth-child(6),
.wallet-front-table th:nth-child(7) {
    text-align: right;
}

.wallet-front-table td:nth-child(1),
.wallet-front-table td:nth-child(2) {
    white-space: nowrap;
}

/* Media query para mobile */
@media screen and (max-width: 768px) {
    .wallet-table-wrapper {
        margin: 10px 0;
        border-radius: 0;
        padding: 0;
    }

    .wallet-filter {
        padding: 10px;
        margin: 10px 0;
        flex-direction: column;
    }

    .wallet-filter select,
    #wallet-filter-apply {
        width: 100%;
        margin: 5px 0;
    }

    .wallet-front-table th,
    .wallet-front-table td {
        padding: 10px;
        font-size: 14px;
    }

    .balance-value {
        font-size: 13px;
    }
}

/* Visão Geral */
.wallet-overview {
    background: #333;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    margin: 20px 0;
    color: #fff;
}

.wallet-overview h3 {
    margin: 0 0 20px 0;
    color: #fff;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.overview-item {
    text-align: center;
    padding: 15px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.overview-item label {
    display: block;
    margin-bottom: 10px;
    color: #fff;
    font-weight: bold;
}

.overview-item span {
    font-size: 20px;
    color: #fff;
    font-weight: bold;
    font-family: monospace;
    transition: all 0.3s ease;
}

/* Estilos para valores ocultos com blur */
.hidden-balance {
    filter: blur(8px);
    -webkit-filter: blur(8px);
}

/* Botão de toggle */
.toggle-balance {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    margin-left: 10px;
    color: #fff;
    transition: color 0.2s;
}

.toggle-balance:hover {
    color: #4169e1;
}

.toggle-balance:focus {
    outline: none;
    box-shadow: none;
}

.toggle-balance .dashicons {
    width: 20px;
    height: 20px;
    font-size: 20px;
}

.balance-value {
    transition: all 0.3s ease;
}

/* Estilos para a listagem admin */
.post-type-wallet .wp-list-table .column-total_invested,
.post-type-wallet .wp-list-table .column-total_profit,
.post-type-wallet .wp-list-table .column-total_withdrawn,
.post-type-wallet .wp-list-table .column-current_balance {
    width: 15%;
    text-align: right;
}

.post-type-wallet .wp-list-table .balance-value {
    font-family: monospace;
    font-size: 14px;
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
    color: #fff;
}

.post-type-wallet .wp-list-table tr:hover .balance-value {
    background: rgba(0, 0, 0, 0.1);
}

/* Container do gráfico */
.wallet-chart-container {
    background: #333;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    padding: 20px;
    margin: 20px 0;
    color: #fff;
}

/* Filtros de ano e mês */
.wallet-chart-filter {
    margin-bottom: 20px;
}

/* Botão de filtrar */
#wallet-chart-year,
#wallet-chart-month {
    padding: 8px;
    margin-right: 10px;
    border: 1px solid #555;
    border-radius: 4px;
    background: #444;
    color: #fff;
}

#wallet-chart-apply {
    padding: 8px 16px;
    background: #4169e1;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

#wallet-chart-apply:hover {
    background: #3158d0;
}

/* Altura fixa para o gráfico */
.chart-wrapper {
    position: relative;
    height: 400px;
    width: 100%;
    margin-bottom: 20px;
}
