/* =========================
   MODAL OVERLAY
========================= */
.modal-overlay {
    position: fixed;
    inset: 0;

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

    display: flex;
    align-items: center;
    justify-content: center;

    z-index: 99999;

    opacity: 0;
    pointer-events: none;

    transition: opacity 0.2s ease;
}

/* 🔥 estado ativo */
.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* =========================
   MODAL BOX
========================= */
.modal-box {
    width: 100%;
    max-width: 900px;
    max-height: 90vh;

    background: var(--color-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);

    display: flex;
    flex-direction: column;

    overflow: hidden;

    transform: translateY(20px);
    transition: transform 0.2s ease;
}

/* animação */
.modal-overlay.active .modal-box {
    transform: translateY(0);
}

/* =========================
   HEADER
========================= */
.modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--color-border);

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.modal-header h5 {
    margin: 0;
    font-size: 16px;
    color: var(--color-text);
}

/* botão fechar */
.modal-header button {
    background: none;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
}

.modal-header button:hover {
    color: var(--color-text);
}

/* =========================
   BODY
========================= */
#modalBody {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}