:root {
    --plataforma-acento: var(--cor-verde);
    --plataforma-acento-fraco: rgba(0, 214, 122, 0.10);
    --plataforma-azul: var(--cor-azul);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.pagina-plataforma-dashboard {
    min-width: 320px;
}

.conteudo-plataforma-dashboard {
    width: min(100%, 1520px);
    margin-inline: auto;
    padding-bottom: clamp(28px, 4vw, 64px);
}

.plataforma-hero {
    position: relative;
    isolation: isolate;
    min-height: clamp(210px, 24vw, 300px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(150px, 230px);
    align-items: center;
    gap: clamp(22px, 4vw, 62px);
    overflow: hidden;
    padding: clamp(28px, 4vw, 52px);
    background:
        radial-gradient(circle at 88% 15%, rgba(0, 214, 122, 0.16), transparent 29%),
        radial-gradient(circle at 72% 100%, rgba(56, 189, 248, 0.09), transparent 30%),
        linear-gradient(135deg, #08271f 0%, #0c2022 52%, #101b2a 100%);
    border: 1px solid rgba(0, 214, 122, 0.28);
    border-radius: clamp(18px, 2vw, 24px);
    box-shadow: var(--sombra-card), inset 0 1px 0 rgba(255,255,255,0.025);
}

.plataforma-hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    right: -70px;
    bottom: -150px;
    width: 360px;
    height: 360px;
    border: 1px solid rgba(56, 189, 248, 0.10);
    border-radius: 50%;
}

.plataforma-etiqueta {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--cor-verde);
    font-size: clamp(10px, .8vw, 12px);
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.plataforma-etiqueta.pequena {
    font-size: 10px;
}

.plataforma-hero h2 {
    max-width: 820px;
    margin-top: 13px;
    color: var(--cor-texto);
    font-family: var(--fonte-titulo);
    font-size: clamp(31px, 3.15vw, 54px);
    font-weight: 900;
    line-height: 1.06;
    letter-spacing: -1.2px;
}

.plataforma-hero p {
    max-width: 860px;
    margin-top: 17px;
    color: #a9bdd0;
    font-size: clamp(13px, 1vw, 16px);
    line-height: 1.7;
}

.plataforma-hero-contador {
    width: clamp(140px, 14vw, 210px);
    aspect-ratio: 1;
    display: grid;
    place-content: center;
    justify-self: end;
    color: var(--cor-texto);
    text-align: center;
    background: linear-gradient(145deg, rgba(0,214,122,.15), rgba(0,214,122,.055));
    border: 1px solid rgba(0,214,122,.34);
    border-radius: 28%;
    box-shadow: 0 24px 55px rgba(0,0,0,.20), inset 0 1px 0 rgba(255,255,255,.04);
    transform: rotate(-3deg);
}

.plataforma-hero-contador strong,
.plataforma-hero-contador span {
    transform: rotate(3deg);
}

.plataforma-hero-contador strong {
    font-family: var(--fonte-titulo);
    font-size: clamp(42px, 5vw, 72px);
    line-height: 1;
}

.plataforma-hero-contador span {
    margin-top: 7px;
    color: var(--cor-verde-claro);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.plataforma-resumo {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(12px, 1.5vw, 20px);
    margin-top: clamp(18px, 2.2vw, 28px);
}

.plataforma-resumo-card {
    min-width: 0;
    padding: clamp(18px, 2vw, 25px);
    background: linear-gradient(145deg, var(--cor-card), #121923);
    border: 1px solid var(--cor-borda);
    border-radius: 16px;
    box-shadow: 0 12px 34px rgba(0,0,0,.16);
}

.plataforma-resumo-card span {
    display: block;
    color: var(--cor-texto-secundario);
    font-size: clamp(11px, .9vw, 13px);
}

.plataforma-resumo-card strong {
    display: block;
    margin-top: 8px;
    color: var(--cor-texto);
    font-family: var(--fonte-titulo);
    font-size: clamp(27px, 2.6vw, 42px);
    font-weight: 900;
    line-height: 1;
}

.painel-plataforma-filtros {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(260px, 520px) auto;
    gap: clamp(14px, 2vw, 24px);
    align-items: end;
    margin-top: clamp(18px, 2.2vw, 28px);
    padding: clamp(20px, 2.4vw, 30px);
    background: linear-gradient(145deg, var(--cor-card), #111821);
    border: 1px solid var(--cor-borda);
    border-radius: 18px;
    box-shadow: var(--sombra-card);
}

.painel-plataforma-textos h2 {
    margin-top: 6px;
    color: var(--cor-texto);
    font-family: var(--fonte-titulo);
    font-size: clamp(20px, 1.8vw, 28px);
    font-weight: 900;
}

.painel-plataforma-textos p {
    margin-top: 4px;
    color: var(--cor-texto-secundario);
    font-size: 12px;
}

.campo-busca-plataforma {
    position: relative;
    display: block;
}

.campo-busca-plataforma > i {
    position: absolute;
    top: 50%;
    left: 15px;
    color: var(--cor-texto-suave);
    transform: translateY(-50%);
    pointer-events: none;
}

.campo-busca-plataforma input {
    width: 100%;
    min-height: 48px;
    padding: 0 15px 0 43px;
    color: var(--cor-texto);
    background: #0d141d;
    border: 1px solid var(--cor-borda);
    border-radius: 11px;
    outline: none;
    font: inherit;
    font-size: 13px;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.campo-busca-plataforma input::placeholder {
    color: #6f8194;
}

.campo-busca-plataforma input:focus {
    background: #0b121a;
    border-color: rgba(0,214,122,.62);
    box-shadow: 0 0 0 3px rgba(0,214,122,.08);
}

.botao-atualizar-plataforma,
.botao-carregar-plataforma {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 18px;
    color: #03130d;
    background: var(--cor-verde);
    border: 1px solid var(--cor-verde);
    border-radius: 11px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 850;
    transition: transform .2s ease, filter .2s ease, opacity .2s ease;
}

.botao-atualizar-plataforma:hover,
.botao-carregar-plataforma:hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
}

.botao-atualizar-plataforma:disabled,
.botao-carregar-plataforma:disabled {
    opacity: .62;
    cursor: wait;
    transform: none;
}

.painel-lista-plataforma {
    min-height: 270px;
    margin-top: clamp(18px, 2vw, 24px);
    padding: clamp(18px, 2.2vw, 28px);
    background: linear-gradient(145deg, var(--cor-card), #111821);
    border: 1px solid var(--cor-borda);
    border-radius: 18px;
    box-shadow: var(--sombra-card);
}

.estado-plataforma {
    min-height: clamp(220px, 28vh, 360px);
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 10px;
    color: var(--cor-texto-secundario);
    text-align: center;
}

.estado-plataforma > i {
    color: var(--cor-texto-suave);
    font-size: 30px;
}

.estado-plataforma strong {
    color: var(--cor-texto);
    font-size: 14px;
}

.estado-plataforma p {
    color: var(--cor-texto-secundario);
    font-size: 12px;
}

.estado-erro-plataforma > i,
.estado-erro-plataforma strong {
    color: var(--cor-vermelho);
}

.carregador-plataforma {
    width: 28px;
    height: 28px;
    border: 3px solid rgba(255,255,255,.10);
    border-top-color: var(--cor-verde);
    border-radius: 50%;
    animation: plataforma-girar .8s linear infinite;
}

@keyframes plataforma-girar { to { transform: rotate(360deg); } }

.grade-provas-plataforma,
.grade-checklists-plataforma {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(14px, 1.7vw, 22px);
    max-height: min(860px, calc(var(--rl-viewport-height) - 230px));
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 2px 5px 8px 2px;
    scrollbar-gutter: stable;
}

.cartao-prova,
.card-checklist-plataforma {
    min-width: 0;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    padding: clamp(17px, 1.7vw, 23px);
    background: linear-gradient(145deg, #19222e, #141c26);
    border: 1px solid var(--cor-borda);
    border-radius: 15px;
    box-shadow: 0 12px 30px rgba(0,0,0,.18);
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.cartao-prova:hover,
.card-checklist-plataforma:hover {
    transform: translateY(-2px);
    border-color: rgba(0,214,122,.38);
    box-shadow: 0 18px 38px rgba(0,0,0,.24);
}

.conteudo-cartao-prova {
    display: flex;
    flex: 1;
    flex-direction: column;
}

.cartao-prova-topo,
.card-checklist-topo {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.cartao-prova h3,
.card-checklist-plataforma h3 {
    color: var(--cor-texto);
    font-family: var(--fonte-titulo);
    font-size: clamp(16px, 1.3vw, 20px);
    font-weight: 900;
    line-height: 1.28;
}

.selo-prova,
.selo-plataforma {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    padding: 5px 8px;
    color: var(--cor-verde-claro);
    background: rgba(0,214,122,.08);
    border: 1px solid rgba(0,214,122,.22);
    border-radius: 999px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.metadados-prova,
.dados-checklist-plataforma {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
    margin-top: 14px;
}

.metadados-prova span,
.dado-checklist-plataforma {
    min-width: 0;
    padding: 8px 7px;
    color: var(--cor-texto-secundario);
    text-align: center;
    background: #101721;
    border: 1px solid rgba(52,66,88,.68);
    border-radius: 8px;
    font-size: 10px;
}

.dado-checklist-plataforma strong {
    display: block;
    color: var(--cor-texto);
    font-size: 12px;
}

.dado-checklist-plataforma span {
    display: block;
    margin-top: 2px;
    color: var(--cor-texto-secundario);
    font-size: 9px;
}

.descricao-prova,
.card-checklist-descricao,
.card-checklist-assunto {
    color: var(--cor-texto-secundario);
    font-size: 11px;
    line-height: 1.6;
}

.descricao-prova,
.card-checklist-descricao {
    display: -webkit-box;
    margin-top: 13px;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.card-checklist-assunto {
    margin-top: 7px;
    color: #a7b8c9;
}

.selo-professor-plataforma {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    max-width: 100%;
    margin-top: 13px;
    padding: 6px 9px;
    color: var(--cor-azul);
    background: rgba(56,189,248,.07);
    border: 1px solid rgba(56,189,248,.18);
    border-radius: 999px;
    font-size: 10px;
    font-weight: 750;
}

.selo-professor-plataforma span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.desempenho-prova {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 13px;
}

.desempenho-prova span,
.status-checklist-plataforma {
    color: var(--cor-texto-secundario);
    font-size: 10px;
    font-weight: 700;
}

.progresso-checklist-plataforma {
    margin-top: 15px;
}

.progresso-checklist-cabecalho {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--cor-texto-secundario);
    font-size: 10px;
}

.progresso-checklist-cabecalho strong {
    color: var(--cor-texto);
}

.progresso-checklist-barra {
    height: 7px;
    margin-top: 7px;
    overflow: hidden;
    background: #0e151e;
    border-radius: 999px;
}

.progresso-checklist-barra > span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--cor-verde-escuro), var(--cor-verde-claro));
    border-radius: inherit;
}

.acoes-prova,
.acoes-checklist-plataforma {
    margin-top: auto;
    padding-top: 17px;
}

.botao-prova,
.botao-checklist-plataforma {
    width: 100%;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #03130d;
    background: var(--cor-verde);
    border: 1px solid var(--cor-verde);
    border-radius: 10px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 850;
    transition: filter .2s ease, transform .2s ease;
}

.botao-prova:hover,
.botao-checklist-plataforma:hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
}

.rodape-carregar-plataforma {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.notificacao-plataforma {
    position: fixed;
    z-index: 2000;
    right: 24px;
    bottom: 24px;
    max-width: min(420px, calc(100vw - 32px));
    padding: 13px 15px;
    color: var(--cor-texto);
    background: #18222e;
    border: 1px solid var(--cor-borda);
    border-radius: 11px;
    box-shadow: 0 18px 45px rgba(0,0,0,.38);
    font-size: 12px;
    line-height: 1.5;
}

.notificacao-plataforma.erro {
    background: #3b171a;
    border-color: rgba(248,113,113,.34);
}

.menu-item-professor .menu-item-icone {
    color: var(--cor-verde);
}

.menu-contador-professores {
    min-width: 19px;
    height: 19px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    padding-inline: 5px;
    color: #03130d;
    background: var(--cor-verde);
    border-radius: 999px;
    font-size: 9px;
    font-weight: 900;
}

@media (max-width: 1220px) {
    .grade-provas-plataforma,
    .grade-checklists-plataforma {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .plataforma-hero {
        grid-template-columns: minmax(0, 1fr) 145px;
    }

    .painel-plataforma-filtros {
        grid-template-columns: 1fr minmax(240px, 1fr);
    }

    .painel-plataforma-filtros .botao-atualizar-plataforma {
        grid-column: 2;
        justify-self: end;
    }
}

@media (max-width: 760px) {
    .conteudo-plataforma-dashboard {
        padding-inline: 16px;
    }

    .plataforma-hero {
        min-height: auto;
        grid-template-columns: 1fr;
        padding: 25px 21px;
    }

    .plataforma-hero-contador {
        width: 118px;
        justify-self: start;
        border-radius: 23px;
    }

    .plataforma-resumo {
        grid-template-columns: 1fr;
    }

    .painel-plataforma-filtros {
        grid-template-columns: 1fr;
    }

    .painel-plataforma-filtros .botao-atualizar-plataforma {
        grid-column: auto;
        width: 100%;
        justify-self: stretch;
    }

    .grade-provas-plataforma,
    .grade-checklists-plataforma {
        grid-template-columns: 1fr;
        max-height: none;
        overflow: visible;
    }
}

@media (max-width: 440px) {
    .plataforma-hero h2 {
        font-size: 29px;
    }

    .metadados-prova,
    .dados-checklist-plataforma {
        grid-template-columns: 1fr;
    }

    .notificacao-plataforma {
        right: 16px;
        bottom: 16px;
    }
}

@media (min-width: 1700px) {
    .conteudo-plataforma-dashboard {
        width: min(100%, 1640px);
    }

    .grade-provas-plataforma,
    .grade-checklists-plataforma {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

/* Catálogo complementar com o mesmo corpo visual das provas oficiais */
.pagina-provas-plataforma-sem-sidebar .conteudo-fase-1 {
    padding-bottom: 60px;
}

.topo-provas-plataforma {
    background:
        radial-gradient(circle at 88% 10%, rgba(255,255,255,.15), transparent 28%),
        linear-gradient(135deg, #123b83 0%, #2563eb 57%, #0891b2 100%);
}

.painel-provas-plataforma-oficial {
    overflow: visible;
}

.painel-plataforma-cabecalho {
    align-items: flex-end;
    gap: 20px;
}

.acoes-catalogo-plataforma {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.pagina-provas-plataforma-sem-sidebar .campo-busca-plataforma {
    width: min(430px, 58vw);
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 13px;
    color: #64748b;
    background: #fff;
    border: 1px solid #dfe7f1;
    border-radius: 11px;
}

.pagina-provas-plataforma-sem-sidebar .campo-busca-plataforma input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #172033;
}

.pagina-provas-plataforma-sem-sidebar .estado-plataforma {
    min-height: 180px;
}

@media (max-width: 760px) {
    .painel-plataforma-cabecalho,
    .acoes-catalogo-plataforma {
        align-items: stretch;
        flex-direction: column;
    }

    .pagina-provas-plataforma-sem-sidebar .campo-busca-plataforma {
        width: 100%;
    }
}


/* Atalho integrado para conteúdos complementares */
.atalho-plataforma-fase {
    width: 100%;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 11px 15px;
    color: #eafff6;
    text-decoration: none;
    background:
        linear-gradient(135deg, rgba(0, 214, 122, .18), rgba(56, 189, 248, .10)),
        #101b24;
    border: 1px solid rgba(0, 214, 122, .42);
    border-radius: 11px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
    font-size: 12px;
    font-weight: 800;
    line-height: 1.25;
    transition:
        transform .18s ease,
        border-color .18s ease,
        background .18s ease,
        box-shadow .18s ease;
}

.atalho-plataforma-fase:hover {
    color: #ffffff;
    background:
        linear-gradient(135deg, rgba(0, 214, 122, .27), rgba(56, 189, 248, .15)),
        #13212c;
    border-color: rgba(56, 232, 155, .72);
    box-shadow: 0 10px 24px rgba(0, 214, 122, .10);
    transform: translateY(-1px);
}

.atalho-plataforma-fase:focus-visible {
    outline: 3px solid rgba(56, 232, 155, .25);
    outline-offset: 2px;
}

.atalho-plataforma-fase .fa-arrow-right {
    margin-left: auto;
    opacity: .72;
}

.acoes-estacoes-oficiais .atalho-plataforma-fase {
    grid-column: 1 / -1;
}

@media (max-width: 700px) {
    .atalho-plataforma-fase {
        justify-content: flex-start;
    }
}

/* Estados do catálogo nunca podem aparecer ao mesmo tempo. */
.estado-plataforma[hidden],
.grade-checklists-plataforma[hidden],
.grade-provas-plataforma[hidden],
.botao-carregar-plataforma[hidden],
.botao-carregar-provas[hidden] {
    display: none !important;
}


/* =========================================================
   V7 — SELEÇÃO SEGURA DE CHECKLIST PARA PRÁTICA EM DUPLA
========================================================= */
.aviso-selecao-checklist-plataforma {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: clamp(16px, 2vw, 24px);
    padding: 16px 18px;
    color: #d1fae5;
    background:
        linear-gradient(
            135deg,
            rgba(0, 214, 122, 0.13),
            rgba(56, 189, 248, 0.07)
        ),
        #0d2223;
    border: 1px solid rgba(45, 212, 191, 0.42);
    border-radius: 14px;
}

.aviso-selecao-checklist-conteudo {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 13px;
}

.aviso-selecao-checklist-conteudo > i {
    flex: 0 0 auto;
    font-size: 20px;
    color: var(--cor-verde-claro);
}

.aviso-selecao-checklist-conteudo strong {
    display: block;
    color: #f0fdf4;
    font-size: 13px;
    font-weight: 900;
}

.aviso-selecao-checklist-conteudo p {
    margin-top: 3px;
    color: #a7c9c2;
    font-size: 11px;
    line-height: 1.5;
}

.botao-cancelar-selecao-plataforma {
    flex: 0 0 auto;
    min-height: 42px;
    padding: 10px 14px;
    color: #fff;
    background: #be123c;
    border: 1px solid #fb7185;
    border-radius: 11px;
    font: inherit;
    font-size: 11px;
    font-weight: 850;
    cursor: pointer;
    transition:
        transform 0.18s ease,
        background 0.18s ease,
        opacity 0.18s ease;
}

.botao-cancelar-selecao-plataforma:hover {
    background: #e11d48;
    transform: translateY(-1px);
}

.botao-cancelar-selecao-plataforma:disabled {
    opacity: 0.62;
    cursor: wait;
    transform: none;
}

@media (max-width: 700px) {
    .aviso-selecao-checklist-plataforma {
        align-items: stretch;
        flex-direction: column;
    }

    .botao-cancelar-selecao-plataforma {
        width: 100%;
    }
}

/* RevalidaLink V3.2 - especificacao no proprio card do checklist */
.botao-checklist-especificacao {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 14px;
    border: 1px solid rgba(118, 156, 191, .34);
    border-radius: 11px;
    background: rgba(20, 39, 56, .7);
    color: #d9e6f2;
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}

.botao-checklist-especificacao:hover {
    background: rgba(31, 57, 79, .86);
}

.card-checklist-especificacao {
    margin-top: 14px;
    padding: 14px;
    border: 1px solid rgba(118, 156, 191, .22);
    border-radius: 13px;
    background: rgba(10, 25, 39, .54);
}

.card-checklist-especificacao[hidden] {
    display: none !important;
}

.card-checklist-especificacao-texto {
    margin: 0 0 12px;
    color: #b7c8d8;
    line-height: 1.55;
}

.card-checklist-especificacao-grade {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 9px;
}

.card-checklist-especificacao-item {
    display: grid;
    gap: 3px;
    padding: 9px 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .045);
}

.card-checklist-especificacao-item span {
    color: #8fa7bc;
    font-size: .75rem;
}

.card-checklist-especificacao-item strong {
    color: #e6eef6;
    font-size: .86rem;
}

@media (max-width: 620px) {
    .acoes-checklist-plataforma > * {
        width: 100%;
    }
}
