/* ══ Jogos Adaptados — estilos ══════════════════════════════════════ */

/* ── Layout geral ─────────────────────────────────────────────────── */
.jg-body-pad {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 48px 64px;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}
@media (max-width: 1024px) { .jg-body-pad { padding: 0 24px 48px; } }
@media (max-width: 640px)  { .jg-body-pad { padding: 0 12px 40px; } }

/* ── Toolbar (busca + filtros) ────────────────────────────────────── */
.jg-toolbar {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.jg-busca-wrap {
    position: relative;
    max-width: 480px;
}
.jg-busca-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #bbb;
    font-size: .9rem;
}
.jg-busca-input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 14px 10px 38px;
    border: 1.5px solid #e0e0e0;
    border-radius: 12px;
    font-size: .88rem;
    font-family: 'Montserrat', sans-serif;
    outline: none;
    background: #fff;
    transition: border-color .15s;
}
.jg-busca-input:focus { border-color: #4caf50; }

.jg-filtros {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.jg-btn-filtro {
    padding: 6px 16px;
    border: 1.5px solid #e0e0e0;
    border-radius: 100px;
    background: #fff;
    font-size: .75rem;
    font-weight: 600;
    font-family: 'Montserrat', sans-serif;
    color: #666;
    cursor: pointer;
    transition: all .15s;
}
.jg-btn-filtro:hover  { border-color: #4caf50; color: #2e7d32; }
.jg-btn-filtro.active { background: #2e7d32; border-color: #2e7d32; color: #fff; }

#jg-contador {
    font-size: .75rem;
    color: #aaa;
    margin-top: 4px;
    margin-bottom: 0;
}

/* ── Grade de cards ───────────────────────────────────────────────── */
.jg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* ── Card do jogo ─────────────────────────────────────────────────── */
.jg-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .15s, box-shadow .15s;
}
.jg-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,.1);
}

.jg-card-header {
    padding: 28px 22px 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    position: relative;
}

.jg-card-emoji {
    font-size: 2.4rem;
    line-height: 1;
}

.jg-card-modulo {
    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: rgba(255,255,255,.85);
    background: rgba(0,0,0,.15);
    border-radius: 100px;
    padding: 3px 10px;
}

.jg-card-titulo {
    font-size: 1.05rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.25;
    margin: 0;
}

.jg-card-mecanica {
    font-size: .68rem;
    font-weight: 600;
    color: rgba(255,255,255,.7);
    text-transform: uppercase;
    letter-spacing: .08em;
}

/* ── Dificuldade (estrelas) ───────────────────────────────────────── */
.jg-dificuldade {
    display: flex;
    gap: 3px;
    position: absolute;
    top: 14px;
    right: 16px;
}
.jg-estrela {
    font-size: .7rem;
    color: rgba(255,255,255,.4);
}
.jg-estrela.on { color: #f9a825; }

/* ── Corpo do card ────────────────────────────────────────────────── */
.jg-card-body {
    padding: 16px 20px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.jg-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.jg-tag {
    font-size: .65rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 100px;
    background: #f5f5f5;
    color: #555;
}

.jg-card-desc {
    font-size: .8rem;
    color: #555;
    line-height: 1.5;
    margin: 0;
    flex: 1;
}

/* ── Botão ────────────────────────────────────────────────────────── */
.jg-card-btn {
    display: block;
    text-align: center;
    padding: 11px;
    border-radius: 12px;
    font-size: .85rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: opacity .15s, transform .1s;
}
.jg-card-btn:hover { opacity: .88; transform: scale(1.01); }
.jg-btn-jogar   { color: #fff; }
.jg-btn-embreve { background: #f5f5f5; color: #aaa; cursor: default; }
.jg-btn-embreve:hover { opacity: 1; transform: none; }

/* ── Dark mode ────────────────────────────────────────────────────── */
body.dark-mode .jg-busca-input,
body.dark-mode .jg-btn-filtro  { background: #1e1e1e; border-color: #333; color: #ccc; }
body.dark-mode .jg-busca-input:focus { border-color: #4caf50; }
body.dark-mode .jg-btn-filtro.active { background: #2e7d32; border-color: #2e7d32; color: #fff; }
body.dark-mode .jg-card        { background: #1e1e1e; border-color: #333; }
body.dark-mode .jg-card-desc   { color: #bbb; }
body.dark-mode .jg-tag         { background: #2a2a2a; color: #aaa; }
body.dark-mode .jg-btn-embreve { background: #2a2a2a; color: #666; }
body.dark-mode #jg-contador    { color: #666; }
