/*
 * Sorteio de nomes — sorteio-de-nomes.php.
 * Usa gerador.css e sorteio.css; aqui ficam etapas, contadores e a lista de ganhadores.
 */

/* Etapas */
.step-num {
    display: inline-grid;
    place-items: center;
    width: 22px;
    height: 22px;
    margin-right: 6px;
    border-radius: 50%;
    background: var(--brand);
    color: #fff;
    font-size: 12px;
}

.step-two {
    padding-top: 20px;
    border-top: 1px solid var(--line);
}

.list-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.list-actions .list-hint {
    margin: 0;
}

/* Contadores */
.raffle-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 16px;
    padding: 0;
    list-style: none;
}

.raffle-stats li {
    padding: 6px 12px;
    border-radius: 999px;
    background: #eef3f8;
    color: var(--ink-soft);
    font-size: 13px;
}

.raffle-stats strong {
    color: var(--ink);
}

.raffle-amount {
    max-width: 260px;
    margin: 0 auto;
    text-align: center;
}

.raffle-amount .list-hint {
    margin-top: 6px;
}

.step-two .draw-options {
    justify-content: center;
}

/* Ganhadores */
.winner-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.winner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(135deg, #f3faff 0%, #fff 100%);
    animation: draw-pop .35s ease both;
}

.winner__pos {
    display: inline-grid;
    flex-shrink: 0;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0a7fd1 0%, #2aa8f2 100%);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
}

.winner__name {
    color: var(--ink);
    font-size: 17px;
    font-weight: 800;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

/* Novo sorteio (abaixo do resultado) */
.new-draw {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
}

.new-draw__title {
    margin: 0 0 12px;
    color: var(--ink);
    font-size: 16px;
    font-weight: 800;
}

.new-draw__options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.draw-result .new-draw__btn {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: none;
    min-height: 72px;
    margin: 0;
    padding: 14px 18px;
    border: 2px solid var(--line);
    border-radius: 16px;
    background: #fff;
    color: var(--ink);
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.draw-result .new-draw__btn:hover {
    border-color: var(--brand);
    background: var(--brand-soft);
    transform: translateY(-1px);
}

.draw-result .new-draw__btn--primary {
    border-color: transparent;
    background: linear-gradient(135deg, #0a7fd1 0%, #2aa8f2 100%);
    color: #fff;
    box-shadow: 0 10px 24px rgba(10, 127, 209, .3);
}

.draw-result .new-draw__btn--primary:hover {
    border-color: transparent;
    background: linear-gradient(135deg, #0a7fd1 0%, #2aa8f2 100%);
    filter: brightness(1.05);
    box-shadow: 0 14px 28px rgba(10, 127, 209, .36);
}

.new-draw__icon {
    display: inline-grid;
    flex-shrink: 0;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--brand-soft);
    color: var(--brand-dark);
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
}

.new-draw__btn--primary .new-draw__icon {
    background: rgba(255, 255, 255, .2);
    color: #fff;
}

.new-draw__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.new-draw__text strong {
    font-size: 16px;
    font-weight: 800;
}

.new-draw__text small {
    font-size: 13px;
    opacity: .8;
}

@media (max-width: 640px) {
    .new-draw__options {
        grid-template-columns: 1fr;
    }
}

/* Um único ganhador ganha destaque */
.winner:only-child {
    grid-column: 1 / -1;
    justify-content: center;
    padding: 24px 16px;
}

.winner:only-child .winner__name {
    font-size: clamp(1.4rem, 5vw, 2rem);
}
