/* ----------------------------------------------------
   GRID PRINCIPAL
---------------------------------------------------- */

#rifa-modal-form p{
    margin:0;
}

.rifa-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    margin-top: 20px;
}

@media (max-width: 600px) {
    .rifa-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}


/* ----------------------------------------------------
   QUADRADOS / BOTÕES
---------------------------------------------------- */

.rifa-number {
    background: #ffffff;
    border: 2px solid #ddd;
    padding: 15px 10px;
    height: 180px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease-in-out;
}

.rifa-number strong {
    font-size: 20px;
}

.rifa-number .rifa-num {
    font-size: 26px;
    font-weight: 700;
}

.rifa-number .rifa-nome {
    font-size: 13px;
    text-align: center;
    margin-top: 4px;
}

.rifa-number .rifa-status {
    font-size: 12px;
    margin-top: 2px;
    text-align: center;
}

.rifa-data{
    font-size: 11px;
    margin-top: 3px;
}

/* Estado: Livre */
.rifa-number.rifa-livre {
    border-color: #28a745;
}

.rifa-number.rifa-livre:hover {
    background: #28a745;
    color: #fff;
}


/* Estado: Pendente */
.rifa-number.rifa-pendente {
    background: #fff9e6;
    border-color: #e6b800;
}

.rifa-number.rifa-pendente .status-text {
    color: #b38f00;
    font-weight: bold;
}


/* Estado: Pago */
.rifa-number.rifa-pago {
    background: #e6ffe9;
    border-color: #28a745;
    cursor: default;
    opacity: 0.75;
}

.rifa-number.rifa-pago .status-text {
    color: #1c7c28;
    font-weight: bold;
}


/* Desabilitado */
.rifa-number:disabled,
.rifa-number[disabled] {
    cursor: not-allowed;
    opacity: 0.7;
}



/* ----------------------------------------------------
   MODAL (AGORA CENTRALIZADO)
---------------------------------------------------- */

/* Fundo escurecido e centralização */
#rifa-modal {
    display: none;                 /* aparece via JS */
    position: fixed;
    inset: 0;                      /* ocupa a tela toda */
    z-index: 99999;

    background: rgba(0, 0, 0, 0.55);

    /* centralização perfeita */
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Conteúdo */
#rifa-modal .rifa-modal-content {
    background: #fff;
    width: 90%;
    max-width: 450px;
    padding: 25px;
    border-radius: 12px;
    position: relative;

    animation: fadeIn 0.25s ease-in-out;
}

/* animação suave */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.rifa-modal-title {
    font-size: 22px;
    margin-bottom: 15px;
    font-weight: 600;
    text-align: center;
}

.rifa-modal-close {
    position: absolute;
    right: 12px;
    top: 12px;
    font-size: 20px;
    cursor: pointer;
}


/* ----------------------------------------------------
   FORMULÁRIO
---------------------------------------------------- */

#rifa-modal-form label {
    font-size: 14px;
    margin-bottom: 4px;
    display: block;
}

#rifa-modal-form input {
    width: 100%;
    padding: 10px;
    font-size: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    outline: none;
    transition: border-color .2s;
    margin-bottom: 12px;
}

#rifa-modal-form input:focus {
    border-color: #0073aa;
}

.rifa-modal-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
}

.rifa-btn-enviar {
    background: #0073aa;
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: 0.2s;
}

.rifa-btn-enviar:hover {
    background: #005f8a;
}

.rifa-modal-cancel {
    background: #aaa;
    color: #fff;
    padding: 10px 18px;
    font-size: 14px;
    border-radius: 6px;
    cursor: pointer;
    border: none;
}

.rifa-modal-cancel:hover {
    background: #888;
}



/* ----------------------------------------------------
   MENSAGEM DE FEEDBACK
---------------------------------------------------- */

.rifa-form-feedback {
    margin-top: 10px;
    font-size: 14px;
    color: #444;
    display: none;
    text-align: center;
}
