@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Hanken Grotesk", sans-serif;
}

body {
    background-color: rgb(241, 245, 249);
}

.no-scroll {
    overflow: hidden;
}

.conteudo {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 0.75rem;
}

/* Topo */

nav.nav {
    display: flex;
    padding: 0.5rem 0.75rem;
    color: #000;
    font-weight: 700;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 1.25rem;
}

.nav img {
    object-fit: contain;
    width: 9rem;
    height: 3rem;
}

.saldo {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 1rem;
    height: 2rem;
    border-radius: 999px;
    background: #a06cf7;
    white-space: nowrap;
}

#saldo-txt {
    color: #fff;
    text-align: center;
    font-weight: 900;
}

/* Card de perguntas */

.box {
    display: flex;
    text-align: center;
    position: relative;
    padding: 0.8rem 1.25rem 1.25rem;
    background-color: #fff;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 0.5rem;
    gap: 0.75rem;
    box-shadow: 0 5px 18px -3px rgb(0 0 0 / 30%);
    width: 100%;
    max-width: 640px;
}

.box h1 {
    line-height: 1.2em;
    color: #a06cf7;
    margin: 5px 0;
    font-size: 24px;
}

.box h2 {
    font-size: 1rem;
    line-height: 1.2em;
    color: rgb(71, 85, 105);
}

.titulo {
    font-size: 0.9rem;
    line-height: 1.2em;
    font-weight: bold;
    color: rgb(71, 85, 105);
    text-align: left;
    display: flex;
    align-items: center;
    gap: 7px;
    margin-right: auto;
}

/* Progresso do quiz */

.progresso {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    width: 100%;
}

.progresso-texto {
    font-size: 0.8rem;
    font-weight: 700;
    color: rgb(100, 116, 139);
    text-align: left;
}

.progresso-barra {
    width: 100%;
    height: 8px;
    background-color: rgb(226, 232, 240);
    border-radius: 999px;
    overflow: hidden;
}

#progresso-fill {
    width: 20%;
    height: 100%;
    background-color: #a06cf7;
    border-radius: 999px;
    transition: width 250ms ease;
}

#quiz-conteudo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
}

.produto {
    width: 100%;
    max-width: 340px;
    height: 210px;
    object-fit: contain;
}

.produto--logo {
    padding: 24px;
    background-color: rgb(248, 250, 252);
    border-radius: 12px;
}

/* Notas */

.notas {
    display: grid;
    justify-content: center;
    align-items: center;
    width: 100%;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.5rem;
}

.nota {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0.7rem 0.625rem;
    border: 0;
    border-radius: 5px;
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 150ms ease;
}

.nota-1 { background: rgb(185, 28, 28); }
.nota-2 { background: rgb(194, 65, 12); }
.nota-3 { background: rgb(202, 138, 4); }
.nota-4 { background: rgb(101, 163, 13); }
.nota-5 { background: rgb(13, 148, 136); }

.opaca {
    opacity: 0.3;
}

[data-grupo].invalido {
    outline: 2px solid #dc2626;
    outline-offset: 4px;
    border-radius: 8px;
}

.clicado {
    opacity: 1 !important;
}

/* Perguntas sim/nao */

.sim_nao {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
}

.sim_nao .sim_nao {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgb(226, 232, 240);
    width: 100%;
    padding: 0.6rem 0;
    border: 0;
    font: inherit;
    font-weight: bold;
    border-radius: 0.25rem;
    color: rgb(51, 65, 85);
    cursor: pointer;
    transition: all 150ms ease;
}

.sim_nao .clicado {
    background-color: #a06cf7;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transform: scale(1.05);
    color: #fff;
}

/* Botao enviar */

#enviar-marca1 {
    width: 100%;
    border: 0;
    background-color: #a06cf7;
    padding: 1.5rem 0;
    border-radius: 0.4rem;
    color: #fff;
    font-weight: 600;
    font-size: 1rem;
    margin-top: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    margin-bottom: 100px;
    box-shadow: 0 5px 18px -3px rgb(0 0 0 / 50%);
    cursor: pointer;
}

/* Modal */

.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    text-align: center;
    align-items: center;
    padding: 16px;
}

.modal.aberto {
    display: flex;
}

.modal-content {
    background-color: #fff;
    margin: auto;
    padding: 20px;
    border-radius: 5px;
    width: 85%;
    max-width: 600px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: modalopen 0.5s;
}

@keyframes modalopen {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.close {
    position: absolute;
    top: 8px;
    right: 14px;
    background: none;
    border: 0;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #000;
}

.modal h2 {
    font-size: 1.2rem;
    color: rgb(51, 65, 85);
    margin: 0 0 15px;
}

.modal p {
    font-size: 0.9rem;
    color: rgba(51, 65, 85, 0.7);
    text-align: center;
    margin: 0 0 15px;
}

#assistir {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    padding: 1rem;
    margin: 10px auto 20px;
    background-color: #7c3aed;
    border-radius: 10px;
    color: #fff;
    font-weight: 700;
    font-size: 1.4rem;
    text-decoration: none;
    animation: pulse 1s ease alternate infinite;
}

@keyframes pulse {
    0% { transform: scale(0.97); }
    100% { transform: scale(1); }
}

/* Checkmark do modal */

.checkmark-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    padding-bottom: 0;
}

.confetti {
    position: absolute;
    animation: grow 1.4s cubic-bezier(0.42, 0, 0.275, 1.155) both alternate-reverse infinite;
}

.confetti:nth-child(1) { width: 12px; height: 12px; left: 12px; top: 16px; animation-delay: 0.7s; }
.confetti:nth-child(2) { width: 18px; height: 18px; left: 168px; top: 84px; animation-delay: 1.4s; }
.confetti:nth-child(3) { width: 10px; height: 10px; left: 32px; top: 162px; animation-delay: 2.1s; }
.confetti:nth-child(4) { width: 20px; height: 20px; left: 82px; top: -12px; animation-delay: 2.8s; }
.confetti:nth-child(5) { width: 14px; height: 14px; left: 125px; top: 162px; animation-delay: 3.5s; }
.confetti:nth-child(6) { width: 10px; height: 10px; left: 16px; top: 16px; animation-delay: 4.2s; }

.checkmark {
    position: relative;
    padding: 30px;
}

.checkmark__check {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 10;
    transform: translate3d(-50%, -50%, 0);
    fill: #fff;
}

.checkmark__back {
    animation: rotate 35s linear both infinite;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes grow {
    0%, 100% { transform: scale(0); }
    50% { transform: scale(1); }
}

/* Foco visivel para navegacao por teclado */

.nota:focus-visible,
.sim_nao .sim_nao:focus-visible,
#enviar-marca1:focus-visible,
#assistir:focus-visible,
.close:focus-visible {
    outline: 3px solid #1d4ed8;
    outline-offset: 3px;
}

