/* ELDERCS panel – efectos (cargar DESPUÉS de custom.css). El fondo lo pone custom.css en <html>. */
:root { --ec-orange: #e58d27; }

/* ---------- Capas de fondo (detrás del contenido) ---------- */
#ec-glow, #ec-grid { position: fixed; inset: 0; pointer-events: none; z-index: -1; }
#ec-glow {
    background:
        radial-gradient(ellipse at 0 0,       rgba(229,141,39,.28), transparent 45%),
        radial-gradient(ellipse at 100% 100%, rgba(229,141,39,.28), transparent 45%);
    animation: ec-breathe 6s ease-in-out infinite;
}
@keyframes ec-breathe { 0%,100% { opacity: .35; } 50% { opacity: 1; } }
#ec-grid {
    background-image:
        linear-gradient(rgba(229,141,39,.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(229,141,39,.07) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse at center, transparent 25%, #000 90%);
            mask-image: radial-gradient(ellipse at center, transparent 25%, #000 90%);
    animation: ec-gridmove 12s linear infinite;
}
@keyframes ec-gridmove { to { background-position: 56px 56px; } }

/* ---------- Brasas ---------- */
#ec-embers { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1000; }

/* ---------- Brillo al pasar el ratón ---------- */
.table tbody tr:hover > td { background-color: rgba(229,141,39,.12) !important; }
.table tbody tr:hover > td:first-child { box-shadow: inset 3px 0 0 var(--ec-orange); }
.ec-live-card { transition: border-color .25s, box-shadow .25s, transform .25s; }
.ec-live-card:hover { border-color: var(--ec-orange) !important; box-shadow: 0 0 22px -4px var(--ec-orange); transform: translateY(-3px); }

/* ---------- Entrada suave (solo en los primeros segundos de carga) ---------- */
html.ec-intro .card, html.ec-intro .ec-featured-server, html.ec-intro .table tbody tr { animation: ec-enter .6s ease both; }
@keyframes ec-enter { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
html.ec-intro #ecLiveStats > div:nth-child(2) .card { animation-delay: .10s; }
html.ec-intro #ecLiveStats > div:nth-child(3) .card { animation-delay: .20s; }
html.ec-intro #ecLiveStats > div:nth-child(4) .card { animation-delay: .30s; }
html.ec-intro .table tbody tr:nth-child(1) { animation-delay: .30s; }
html.ec-intro .table tbody tr:nth-child(2) { animation-delay: .35s; }
html.ec-intro .table tbody tr:nth-child(3) { animation-delay: .40s; }
html.ec-intro .table tbody tr:nth-child(4) { animation-delay: .45s; }
html.ec-intro .table tbody tr:nth-child(n+5) { animation-delay: .50s; }

/* ---------- Barra de ocupación ---------- */
.ec-featured-bar { height: 10px; border-radius: 10px; background: rgba(255,255,255,.10); border: 1px solid rgba(229,141,39,.25); margin: 12px 0 6px; overflow: hidden; }
.ec-featured-bar i { display: block; height: 100%; width: 0; min-width: 6px; border-radius: 10px;
    background: linear-gradient(90deg, #e58d27, #ffb454); box-shadow: 0 0 10px rgba(229,141,39,.6); transition: width 1s ease; }
.ec-featured-bar.hot i { background: linear-gradient(90deg, #e55a27, #ff3b3b); box-shadow: 0 0 10px rgba(255,59,59,.6); }

/* ---------- Punto que late en "N Active" ---------- */
.dash-active-stat.ec-has::before {
    content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%;
    background: currentColor; margin-right: 6px; vertical-align: middle;
    animation: ec-dot 1.4s ease-in-out infinite;
}
@keyframes ec-dot { 0%,100% { box-shadow: 0 0 0 0 currentColor; } 70% { box-shadow: 0 0 0 7px transparent; } }

/* ---------- Medallas del Top Players ---------- */
.ec-medal { font-size: 22px; filter: drop-shadow(0 0 6px currentColor); }
.ec-m1 { color: #ffd24a; } .ec-m2 { color: #d3dae2; } .ec-m3 { color: #b8642a; }

/* ---------- Esqueleto de carga ---------- */
html.ec-loading .card, html.ec-loading .ec-featured-server { position: relative; }
html.ec-loading .card::after, html.ec-loading .ec-featured-server::after {
    content: ''; position: absolute; inset: 0; border-radius: inherit; z-index: 5; pointer-events: none;
    background: linear-gradient(100deg, rgba(255,255,255,0) 30%, rgba(229,141,39,.14) 50%, rgba(255,255,255,0) 70%) 0 0 / 200% 100%,
                rgba(10,10,12,.55);
    animation: ec-shimmer 1.2s linear infinite;
}
@keyframes ec-shimmer { from { background-position: 200% 0, 0 0; } to { background-position: -200% 0, 0 0; } }


/* ---------- "+N hoy" bajo Bans / Mutes ---------- */
.ec-today { margin-top: 6px; font-size: 12px; font-weight: 600; letter-spacing: .3px; color: #8a8f98; }
.ec-today.ec-has { color: #ffb454; text-shadow: 0 0 10px rgba(229,141,39,.5); }

/* ---------- Tarjeta del servidor: foto del mapa más ancha ---------- */
@media (min-width: 992px) {
    .ec-featured-server { display: grid !important; grid-template-columns: 340px 1fr !important; }
    .ec-featured-map { min-height: 230px; background-size: cover !important; background-position: center !important; }
}
.ec-featured-map-copy { text-shadow: 0 2px 8px rgba(0,0,0,.9); }
.ec-featured-map-copy strong { text-shadow: 0 2px 10px rgba(0,0,0,.95); }

/* Las 4 tarjetas KPI, misma altura */
#ecLiveStats .ec-live-card { height: 100%; }
#ecLiveStats .ec-today { min-height: 18px; }
#ecLiveStats { align-items: stretch; }
#ecLiveStats > [class*="col-"] { display: flex; }
#ecLiveStats > [class*="col-"] > .card, #ecLiveStats > [class*="col-"] > .ec-card-link { flex: 1 1 auto; width: 100%; }

/* Tarjetas KPI clicables */
.ec-card-link, .ec-card-link:hover, .ec-card-link:focus { display: flex; color: inherit; text-decoration: none; cursor: pointer; }
.ec-card-link .card { width: 100%; }
.ec-card-link:focus-visible .card { outline: 2px solid var(--ec-orange); outline-offset: 2px; }
html { scroll-behavior: smooth; }
