/* ============================================================
   WYD ODIN - PAINEL WEB
   Arquivo: style.css
   Descrição: Estilo visual completo (tema preto/dourado medieval)
   ============================================================ */

:root {
    --cor-fundo: #0a0a0d;
    --cor-fundo-alt: #121216;
    --cor-superficie: #17171c;
    --cor-superficie-alt: #1e1e25;
    --cor-borda: #2a2a33;

    --cor-dourado: #d4af37;
    --cor-dourado-claro: #f4d976;
    --cor-dourado-escuro: #9c7c1f;

    --cor-texto: #e9e6dd;
    --cor-texto-suave: #a8a6a0;
    --cor-texto-fraco: #6f6d68;

    --cor-verde: #3ecf8e;
    --cor-vermelho: #e5484d;
    --cor-azul: #4a9eff;
    --cor-roxo: #a374f0;

    --gradiente-dourado: linear-gradient(135deg, #f4d976 0%, #d4af37 50%, #9c7c1f 100%);
    --gradiente-escuro: linear-gradient(180deg, #17171c 0%, #0a0a0d 100%);

    --sombra-card: 0 8px 24px rgba(0, 0, 0, 0.45);
    --sombra-dourada: 0 0 24px rgba(212, 175, 55, 0.25);

    --raio: 14px;
    --raio-sm: 8px;

    --font-titulo: 'Cinzel', serif;
    --font-corpo: 'Poppins', sans-serif;
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    background-color: var(--cor-fundo);
    color: var(--cor-texto);
    font-family: var(--font-corpo);
    margin: 0;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ============================================================
   TELA DE LOGIN
   ============================================================ */

.login-page {
    background:
        radial-gradient(circle at 20% 20%, rgba(212, 175, 55, 0.08), transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(163, 116, 240, 0.08), transparent 40%),
        var(--cor-fundo);
    background-attachment: fixed;
    position: relative;
    overflow-x: hidden;
}

.login-bg-overlay {
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(10, 10, 13, 0.85), rgba(10, 10, 13, 0.92)),
        repeating-linear-gradient(45deg, rgba(212, 175, 55, 0.03) 0px, rgba(212, 175, 55, 0.03) 2px, transparent 2px, transparent 40px);
    z-index: 0;
}

.login-container {
    position: relative;
    z-index: 1;
}

.login-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    padding: 2.5rem 2rem;
    box-shadow: var(--sombra-card), var(--sombra-dourada);
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradiente-dourado);
}

.login-header {
    margin-bottom: 1.75rem;
}

.login-logo {
    width: 100%;
    max-width: 260px;
    margin: 0 auto 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-logo img {
    width: 100%;
    height: auto;
    display: block;
    filter: drop-shadow(0 0 22px rgba(243,206,107,0.35));
}

.login-title {
    font-family: var(--font-titulo);
    font-weight: 800;
    font-size: 1.9rem;
    letter-spacing: 2px;
    color: var(--cor-texto);
    margin: 0;
}

.login-title span {
    color: var(--cor-dourado);
}

.login-subtitle {
    color: var(--cor-texto-suave);
    font-size: 0.9rem;
    margin-top: 0.35rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.login-footer {
    margin-top: 1.5rem;
}

.login-footer p {
    color: var(--cor-texto-fraco);
    font-size: 0.78rem;
    margin: 0;
}

/* ============================================================
   FORMULÁRIOS (customização geral)
   ============================================================ */

.form-floating-custom label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--cor-texto-suave);
    margin-bottom: 0.45rem;
}

.custom-input {
    background: var(--cor-fundo-alt);
    border: 1px solid var(--cor-borda);
    color: var(--cor-texto);
    border-radius: var(--raio-sm);
    padding: 0.7rem 0.9rem;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.custom-input:focus {
    background: var(--cor-fundo-alt);
    color: var(--cor-texto);
    border-color: var(--cor-dourado);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
}

.custom-input::placeholder {
    color: var(--cor-texto-fraco);
}

.btn-gold {
    background: var(--gradiente-dourado);
    border: none;
    color: #14140f;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 0.75rem 1rem;
    border-radius: var(--raio-sm);
    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.btn-gold:hover {
    transform: translateY(-2px);
    box-shadow: var(--sombra-dourada);
    filter: brightness(1.08);
    color: #14140f;
}

.btn-gold-outline {
    background: transparent;
    border: 1.5px solid var(--cor-dourado);
    color: var(--cor-dourado);
    font-weight: 600;
    padding: 0.55rem 1.1rem;
    border-radius: var(--raio-sm);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-gold-outline:hover {
    background: var(--gradiente-dourado);
    color: #14140f;
}

.alert-custom {
    border: 1px solid transparent;
    border-radius: var(--raio-sm);
    font-size: 0.88rem;
}

.alert-danger.alert-custom {
    background: rgba(229, 72, 77, 0.12);
    border-color: rgba(229, 72, 77, 0.35);
    color: #ff8a8d;
}

.alert-success.alert-custom {
    background: rgba(62, 207, 142, 0.12);
    border-color: rgba(62, 207, 142, 0.35);
    color: #6ee7ae;
}

/* ============================================================
   LAYOUT DO PAINEL (SIDEBAR + CONTEÚDO)
   ============================================================ */

.painel-body {
    background: var(--cor-fundo);
}

.painel-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ---------- SIDEBAR ---------- */

.sidebar {
    width: 260px;
    flex-shrink: 0;
    background: var(--gradiente-escuro);
    border-right: 1px solid var(--cor-borda);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1030;
    transition: transform 0.25s ease;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 1.5rem 1.25rem;
    font-family: var(--font-titulo);
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--cor-texto);
    border-bottom: 1px solid var(--cor-borda);
    letter-spacing: 1px;
}

.sidebar-brand i {
    color: var(--cor-dourado);
    font-size: 1.4rem;
}

.sidebar-brand img {
    width: 100%;
    max-width: 190px;
    height: auto;
    display: block;
}

.sidebar-brand b {
    color: var(--cor-dourado);
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.1rem 1.25rem;
    border-bottom: 1px solid var(--cor-borda);
}

.sidebar-user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--gradiente-dourado);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #14140f;
    font-size: 1.05rem;
    flex-shrink: 0;
}

.sidebar-user-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sidebar-user-name {
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--cor-texto);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-user-badge {
    font-size: 0.72rem;
    color: var(--cor-dourado);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sidebar-menu {
    flex: 1;
    padding: 1rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.75rem 1rem;
    border-radius: var(--raio-sm);
    color: var(--cor-texto-suave);
    font-weight: 500;
    font-size: 0.92rem;
    transition: background 0.18s ease, color 0.18s ease, transform 0.15s ease;
}

.sidebar-link i {
    width: 20px;
    text-align: center;
    font-size: 1.02rem;
}

.sidebar-link:hover {
    background: var(--cor-superficie-alt);
    color: var(--cor-dourado-claro);
    transform: translateX(3px);
}

.sidebar-link.active {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.16), transparent);
    color: var(--cor-dourado);
    border-left: 3px solid var(--cor-dourado);
    padding-left: calc(1rem - 3px);
}

.sidebar-link-logout {
    margin-top: auto;
    color: #ff8a8d;
}

.sidebar-link-logout:hover {
    background: rgba(229, 72, 77, 0.12);
    color: #ff8a8d;
}

.sidebar-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--cor-borda);
}

.sidebar-footer p {
    margin: 0;
    font-size: 0.72rem;
    color: var(--cor-texto-fraco);
}

/* ---------- CONTEÚDO ---------- */

.painel-content {
    flex: 1;
    margin-left: 260px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.75rem;
    background: var(--cor-superficie);
    border-bottom: 1px solid var(--cor-borda);
    position: sticky;
    top: 0;
    z-index: 1020;
}

.btn-toggle-sidebar {
    display: none;
    background: transparent;
    border: 1px solid var(--cor-borda);
    color: var(--cor-texto);
    width: 40px;
    height: 40px;
    border-radius: var(--raio-sm);
    align-items: center;
    justify-content: center;
}

.topbar-title {
    font-family: var(--font-titulo);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--cor-texto);
    margin: 0;
    flex: 1;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.topbar-rubis {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.3);
    color: var(--cor-dourado-claro);
    padding: 0.45rem 0.9rem;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
}

.topbar-user-btn {
    background: var(--cor-superficie-alt);
    border: 1px solid var(--cor-borda);
    color: var(--cor-texto);
    border-radius: 30px;
    padding: 0.5rem 1rem;
    font-size: 0.87rem;
    font-weight: 500;
}

.topbar-user-btn:hover,
.topbar-user-btn:focus {
    background: var(--cor-superficie-alt);
    color: var(--cor-dourado-claro);
    border-color: var(--cor-dourado);
}

.custom-dropdown {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio-sm);
    min-width: 190px;
    padding: 0.4rem;
}

.custom-dropdown .dropdown-item {
    color: var(--cor-texto-suave);
    border-radius: 6px;
    padding: 0.55rem 0.75rem;
    font-size: 0.87rem;
}

.custom-dropdown .dropdown-item:hover {
    background: var(--cor-superficie-alt);
    color: var(--cor-dourado-claro);
}

.custom-dropdown .dropdown-divider {
    border-color: var(--cor-borda);
}

.painel-main {
    flex: 1;
    padding: 1.75rem;
}

.painel-footer {
    padding: 1rem 1.75rem;
    text-align: center;
    border-top: 1px solid var(--cor-borda);
}

.painel-footer p {
    margin: 0;
    font-size: 0.78rem;
    color: var(--cor-texto-fraco);
}

/* ============================================================
   DASHBOARD CARDS
   ============================================================ */

.dash-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--sombra-card);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}

.dash-card:hover {
    transform: translateY(-4px);
    border-color: var(--cor-dourado);
    box-shadow: var(--sombra-card), var(--sombra-dourada);
}

.dash-card-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.icon-gold {
    background: rgba(212, 175, 55, 0.15);
    color: var(--cor-dourado);
}

.icon-green {
    background: rgba(62, 207, 142, 0.15);
    color: var(--cor-verde);
}

.icon-purple {
    background: rgba(163, 116, 240, 0.15);
    color: var(--cor-roxo);
}

.icon-blue {
    background: rgba(74, 158, 255, 0.15);
    color: var(--cor-azul);
}

.dash-card-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dash-card-label {
    font-size: 0.75rem;
    color: var(--cor-texto-fraco);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.15rem;
}

.dash-card-value {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--cor-texto);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dash-card-value-sm {
    font-size: 0.95rem;
}

.badge-status {
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
}

.badge-status.online {
    background: rgba(62, 207, 142, 0.15);
    color: var(--cor-verde);
}

.badge-status.offline {
    background: rgba(229, 72, 77, 0.15);
    color: var(--cor-vermelho);
}

/* ---------- DESTAQUE ---------- */

.destaque-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    overflow: hidden;
    box-shadow: var(--sombra-card);
}

.destaque-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.14), transparent);
    padding: 0.9rem 1.5rem;
    border-bottom: 1px solid var(--cor-borda);
}

.destaque-header i {
    color: var(--cor-dourado);
    font-size: 1.1rem;
}

.destaque-header h2 {
    font-family: var(--font-titulo);
    font-size: 1.05rem;
    margin: 0;
    color: var(--cor-texto);
}

.destaque-body {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.5rem;
    flex-wrap: wrap;
}

.destaque-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--gradiente-dourado);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: #14140f;
    flex-shrink: 0;
}

.destaque-info {
    flex: 1;
    min-width: 200px;
}

.destaque-info h3 {
    font-family: var(--font-titulo);
    font-size: 1.3rem;
    margin: 0 0 0.5rem;
    color: var(--cor-texto);
}

.destaque-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.destaque-action {
    margin-left: auto;
}

/* ============================================================
   PERSONAGENS ONLINE (TEMPO REAL)
   ============================================================ */

.live-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    overflow: hidden;
    box-shadow: var(--sombra-card);
}

.live-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    background: linear-gradient(90deg, rgba(62, 207, 142, 0.12), transparent);
    padding: 0.9rem 1.5rem;
    border-bottom: 1px solid var(--cor-borda);
}

.live-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.live-title i {
    color: var(--cor-verde);
    font-size: 1.1rem;
}

.live-title h2 {
    font-family: var(--font-titulo);
    font-size: 1.05rem;
    margin: 0;
    color: var(--cor-texto);
}

.live-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(62, 207, 142, 0.12);
    border: 1px solid rgba(62, 207, 142, 0.35);
    color: var(--cor-verde);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.22rem 0.6rem;
    border-radius: 20px;
}

.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--cor-verde);
    animation: live-pulse 1.6s ease-in-out infinite;
}

@keyframes live-pulse {
    0% { box-shadow: 0 0 0 0 rgba(62, 207, 142, 0.55); }
    70% { box-shadow: 0 0 0 7px rgba(62, 207, 142, 0); }
    100% { box-shadow: 0 0 0 0 rgba(62, 207, 142, 0); }
}

.live-updated {
    font-size: 0.75rem;
    color: var(--cor-texto-fraco);
    transition: opacity 0.2s ease;
}

.live-body {
    padding: 1.5rem;
}

.live-body.is-refreshing {
    opacity: 0.55;
    transition: opacity 0.2s ease;
}

.live-empty {
    text-align: center;
    padding: 2.25rem 1rem;
    color: var(--cor-texto-suave);
}

.live-empty i {
    font-size: 1.8rem;
    color: var(--cor-texto-fraco);
    margin-bottom: 0.6rem;
    display: block;
}

.live-empty p {
    margin: 0;
    font-size: 0.9rem;
}

/* ============================================================
   RANKING
   ============================================================ */

.ranking-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    overflow: hidden;
    box-shadow: var(--sombra-card);
    position: relative;
    isolation: isolate;
}

/* Textura estilo anime: screentone (pontinhos de mangá) + scanlines sutis */
.ranking-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        radial-gradient(rgba(212, 175, 55, 0.10) 1px, transparent 1px),
        repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0px, rgba(255, 255, 255, 0.02) 1px, transparent 1px, transparent 3px);
    background-size: 12px 12px, auto;
    opacity: 0.6;
}

.ranking-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.14), transparent);
    padding: 0.9rem 1.5rem;
    border-bottom: 1px solid var(--cor-borda);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* Linhas de velocidade estilo anime no cabeçalho */
.ranking-header::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image: repeating-linear-gradient(
        112deg,
        rgba(212, 175, 55, 0.08) 0px,
        rgba(212, 175, 55, 0.08) 2px,
        transparent 2px,
        transparent 26px
    );
    mask-image: linear-gradient(90deg, black, transparent 75%);
    -webkit-mask-image: linear-gradient(90deg, black, transparent 75%);
}

.table-responsive {
    position: relative;
    z-index: 1;
}

.ranking-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.ranking-title i {
    color: var(--cor-dourado);
    font-size: 1.1rem;
}

.ranking-title h2 {
    font-family: var(--font-titulo);
    font-size: 1.05rem;
    margin: 0;
    color: var(--cor-texto);
}

.ranking-subtitle {
    font-size: 0.78rem;
    color: var(--cor-texto-fraco);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ranking-table {
    color: var(--cor-texto);
    margin: 0;
}

.ranking-table thead th {
    background: var(--cor-fundo-alt);
    color: var(--cor-texto-fraco);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 700;
    border-bottom: 1px solid var(--cor-borda);
    padding: 0.85rem 1.25rem;
    white-space: nowrap;
}

.ranking-table tbody td {
    padding: 0.85rem 1.25rem;
    border-bottom: 1px solid var(--cor-borda);
    background: transparent;
}

.ranking-table tbody tr:last-child td {
    border-bottom: none;
}

.ranking-table tbody tr:hover td {
    background: var(--cor-superficie-alt);
}

.ranking-row-voce td {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.1), transparent);
}

.ranking-row-voce:hover td {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.16), transparent);
}

.col-pos {
    width: 70px;
}

.col-level {
    width: 110px;
    text-align: right;
}

.ranking-pos-num {
    color: var(--cor-texto-fraco);
    font-weight: 700;
    font-size: 0.85rem;
}

.ranking-medal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 0.9rem;
}

.medal-gold {
    background: linear-gradient(135deg, #f4d976, #d4af37);
    color: #14140f;
    box-shadow: var(--sombra-dourada);
}

.medal-silver {
    background: linear-gradient(135deg, #e6e6e6, #b0b0b0);
    color: #14140f;
}

.medal-bronze {
    background: linear-gradient(135deg, #cd8a52, #8a5a2e);
    color: #14140f;
}

.ranking-nome {
    font-weight: 600;
    color: var(--cor-texto);
}

.ranking-led {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    margin-right: 0.55rem;
    vertical-align: middle;
    background: var(--cor-texto-fraco);
}

.ranking-led.is-online {
    background: var(--cor-verde);
    box-shadow: 0 0 6px 2px rgba(62, 207, 142, 0.75), 0 0 14px 4px rgba(62, 207, 142, 0.35);
    animation: ranking-led-blink 1.6s ease-in-out infinite;
}

@keyframes ranking-led-blink {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 6px 2px rgba(62, 207, 142, 0.75), 0 0 14px 4px rgba(62, 207, 142, 0.35);
    }
    50% {
        opacity: 0.55;
        box-shadow: 0 0 3px 1px rgba(62, 207, 142, 0.45), 0 0 8px 2px rgba(62, 207, 142, 0.15);
    }
}

@keyframes ranking-led-acender {
    0% {
        transform: scale(0.4);
        box-shadow: 0 0 0 0 rgba(62, 207, 142, 0);
    }
    40% {
        transform: scale(1.8);
        box-shadow: 0 0 12px 6px rgba(62, 207, 142, 0.9);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 6px 2px rgba(62, 207, 142, 0.75), 0 0 14px 4px rgba(62, 207, 142, 0.35);
    }
}

.ranking-led-acender {
    animation: ranking-led-acender 0.9s ease;
}

.ranking-row-online td {
    background: linear-gradient(90deg, rgba(62, 207, 142, 0.07), transparent 65%);
}

.ranking-row-online.ranking-row-voce td {
    background: linear-gradient(90deg, rgba(62, 207, 142, 0.09), rgba(212, 175, 55, 0.08) 55%, transparent);
}

.ranking-row-online td.col-pos {
    box-shadow: inset 3px 0 0 0 rgba(62, 207, 142, 0.55);
}

.ranking-badge-voce {
    margin-left: 0.5rem;
}

.ranking-level {
    font-weight: 700;
    color: var(--cor-dourado-claro);
    font-size: 1rem;
}

/* ---------- Efeitos de atualização em tempo real ---------- */

@keyframes ranking-flash-up {
    0% { background-color: rgba(62, 207, 142, 0); }
    25% { background-color: rgba(62, 207, 142, 0.22); }
    100% { background-color: rgba(62, 207, 142, 0); }
}

@keyframes ranking-flash-down {
    0% { background-color: rgba(229, 72, 77, 0); }
    25% { background-color: rgba(229, 72, 77, 0.18); }
    100% { background-color: rgba(229, 72, 77, 0); }
}

@keyframes ranking-flash-new {
    0% { background-color: rgba(212, 175, 55, 0); }
    25% { background-color: rgba(212, 175, 55, 0.25); }
    100% { background-color: rgba(212, 175, 55, 0); }
}

@keyframes level-pulse-anim {
    0% { transform: scale(1); color: var(--cor-dourado-claro); text-shadow: none; }
    35% { transform: scale(1.35); color: #fff3c4; text-shadow: 0 0 10px rgba(244, 217, 118, 0.9); }
    100% { transform: scale(1); color: var(--cor-dourado-claro); text-shadow: none; }
}

.ranking-row-up td {
    animation: ranking-flash-up 1.4s ease;
}

.ranking-row-down td {
    animation: ranking-flash-down 1.4s ease;
}

.ranking-row-new td {
    animation: ranking-flash-new 1.8s ease;
}

.ranking-table tbody tr {
    will-change: transform;
}

.level-pulse {
    display: inline-block;
    animation: level-pulse-anim 0.7s ease;
}

/* ---------- Toast de comemoração (subiu de posição) ---------- */

.ranking-toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    max-width: 320px;
    pointer-events: none;
}

.ranking-toast {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: linear-gradient(135deg, #1c1c22, #121216);
    border: 1px solid var(--cor-dourado);
    box-shadow: var(--sombra-card), var(--sombra-dourada);
    border-radius: var(--raio-sm);
    padding: 0.85rem 1.1rem;
    opacity: 0;
    transform: translateX(30px) scale(0.95);
    transition: opacity 0.35s ease, transform 0.35s ease;
    pointer-events: auto;
}

.ranking-toast.show {
    opacity: 1;
    transform: translateX(0) scale(1);
}

.ranking-toast.hide {
    opacity: 0;
    transform: translateX(30px) scale(0.95);
}

.ranking-toast-icon {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--gradiente-dourado);
    color: #14140f;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    animation: ranking-toast-icon-pop 0.5s ease;
}

@keyframes ranking-toast-icon-pop {
    0% { transform: scale(0.3) rotate(-15deg); }
    60% { transform: scale(1.15) rotate(8deg); }
    100% { transform: scale(1) rotate(0deg); }
}

.ranking-toast-text {
    font-size: 0.85rem;
    color: var(--cor-texto);
    line-height: 1.35;
}

.ranking-toast-text strong {
    color: var(--cor-dourado-claro);
}

@media (max-width: 575.98px) {
    .ranking-toast-container {
        left: 1rem;
        right: 1rem;
        max-width: none;
    }
}

@media (max-width: 575.98px) {
    .ranking-table thead th,
    .ranking-table tbody td {
        padding: 0.65rem 0.85rem;
        font-size: 0.85rem;
    }

    .ranking-subtitle {
        display: none;
    }
}

/* ============================================================
   TAGS / BADGES
   ============================================================ */

.tag {
    display: inline-flex;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.28rem 0.65rem;
    border-radius: 20px;
    letter-spacing: 0.3px;
}

.tag-gold {
    background: rgba(212, 175, 55, 0.15);
    color: var(--cor-dourado-claro);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.tag-blue {
    background: rgba(74, 158, 255, 0.15);
    color: var(--cor-azul);
    border: 1px solid rgba(74, 158, 255, 0.3);
}

.tag-purple {
    background: rgba(163, 116, 240, 0.15);
    color: var(--cor-roxo);
    border: 1px solid rgba(163, 116, 240, 0.3);
}

.tag-green {
    background: rgba(62, 207, 142, 0.15);
    color: var(--cor-verde);
    border: 1px solid rgba(62, 207, 142, 0.3);
}

/* ============================================================
   PERSONAGENS - CARDS
   ============================================================ */

.char-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    padding: 1.25rem;
    box-shadow: var(--sombra-card);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.char-card:hover {
    transform: translateY(-4px);
    border-color: var(--cor-dourado);
    box-shadow: var(--sombra-card), var(--sombra-dourada);
}

.char-card-top {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.char-avatar {
    position: relative;
    width: 54px;
    height: 54px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.22), rgba(212, 175, 55, 0.05));
    border: 1px solid rgba(212, 175, 55, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--cor-dourado);
    flex-shrink: 0;
}

.char-status-dot {
    position: absolute;
    bottom: -3px;
    right: -3px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid var(--cor-superficie);
}

.char-status-dot.is-online {
    background: var(--cor-verde);
}

.char-status-dot.is-offline {
    background: var(--cor-texto-fraco);
}

.char-title {
    flex: 1;
    overflow: hidden;
}

.char-title h3 {
    font-family: var(--font-titulo);
    font-size: 1.1rem;
    margin: 0;
    color: var(--cor-texto);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.char-class {
    font-size: 0.8rem;
    color: var(--cor-texto-suave);
}

.char-level-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--gradiente-dourado);
    color: #14140f;
    border-radius: 10px;
    padding: 0.35rem 0.65rem;
    line-height: 1;
    flex-shrink: 0;
}

.char-level-badge span {
    font-size: 0.62rem;
    font-weight: 700;
}

.char-level-badge strong {
    font-size: 1.05rem;
}

.char-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.char-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    background: var(--cor-fundo-alt);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio-sm);
    padding: 0.85rem;
}

.char-stat {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.char-stat i {
    color: var(--cor-dourado);
    width: 18px;
    text-align: center;
}

.char-stat-label {
    display: block;
    font-size: 0.68rem;
    color: var(--cor-texto-fraco);
    text-transform: uppercase;
}

.char-stat-value {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--cor-texto);
}

.char-frags {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.char-frag-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.82rem;
    color: var(--cor-texto-suave);
    border-bottom: 1px dashed var(--cor-borda);
    padding-bottom: 0.35rem;
}

.char-frag-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.frag-value {
    font-weight: 700;
    color: var(--cor-dourado-claro);
}

.char-footer {
    border-top: 1px solid var(--cor-borda);
    padding-top: 0.75rem;
}

.char-status-text {
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.char-status-text i {
    font-size: 0.55rem;
}

.text-online {
    color: var(--cor-verde);
}

.text-offline {
    color: var(--cor-texto-fraco);
}

/* ============================================================
   FORM CARD (Alterar Senha)
   ============================================================ */

.form-card {
    background: var(--cor-superficie);
    border: 1px solid var(--cor-borda);
    border-radius: var(--raio);
    padding: 2rem;
    box-shadow: var(--sombra-card);
}

.form-card-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.form-card-header i {
    font-size: 2rem;
    color: var(--cor-dourado);
    margin-bottom: 0.5rem;
}

.form-card-header h2 {
    font-family: var(--font-titulo);
    font-size: 1.3rem;
    margin: 0.3rem 0;
    color: var(--cor-texto);
}

.form-card-header p {
    color: var(--cor-texto-suave);
    font-size: 0.85rem;
    margin: 0;
}

/* ============================================================
   EMPTY STATE
   ============================================================ */

.empty-state {
    text-align: center;
    padding: 4rem 1.5rem;
    background: var(--cor-superficie);
    border: 1px dashed var(--cor-borda);
    border-radius: var(--raio);
}

.empty-state i {
    font-size: 2.75rem;
    color: var(--cor-dourado-escuro);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-family: var(--font-titulo);
    color: var(--cor-texto);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--cor-texto-suave);
    margin: 0;
}

/* ============================================================
   RESPONSIVIDADE
   ============================================================ */

@media (max-width: 991.98px) {
    .sidebar {
        transform: translateX(-100%);
        box-shadow: 8px 0 30px rgba(0, 0, 0, 0.6);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .painel-content {
        margin-left: 0;
    }

    .btn-toggle-sidebar {
        display: flex;
    }

    .topbar-title {
        font-size: 1.05rem;
    }

    .topbar-rubis span {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .painel-main {
        padding: 1.1rem;
    }

    .topbar {
        padding: 0.85rem 1rem;
    }

    .dash-card-value {
        font-size: 1rem;
    }

    .destaque-body {
        flex-direction: column;
        text-align: center;
    }

    .destaque-action {
        margin-left: 0;
        width: 100%;
    }

    .destaque-action .btn-gold-outline {
        width: 100%;
    }
}

/* Overlay para fechar sidebar no mobile */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1025;
}

.sidebar-overlay.show {
    display: block;
}
